From 836426985a47a5c6f33e48265b063a834ab27592 Mon Sep 17 00:00:00 2001 From: "Peter Fichtner (pfichtner)" Date: Fri, 31 May 2024 16:20:19 +0200 Subject: [PATCH 1/3] Initial version Please feel free to merge even without a PR if suitable and delete the branch --- _kata_descriptions/bingo.md | 38 +++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 _kata_descriptions/bingo.md diff --git a/_kata_descriptions/bingo.md b/_kata_descriptions/bingo.md new file mode 100644 index 0000000..1391562 --- /dev/null +++ b/_kata_descriptions/bingo.md @@ -0,0 +1,38 @@ +--- +title: Bingo Refactoring Kata +kata_name: bingo +--- + +# Bingo Refactoring Kata + +This kata is used for practicing refactoring. The code contains at least the code smells: + +- primitive obsession +- data clumps +- missing polymorphism (Board/InitializedBoard/...) +- long methods + +The structure of the Bingo Refactoring Kata is similar to the Game of Life kata, but since the focus here is on refactoring, the business rules should be kept as simple as possible. It is not absolutely necessary to understand the business rules in order to complete the task. +The business rules are: + +- A bingo board must be initialized before it can be used/played +- A board is initialized when each cell has been assigned a value +- A cell may not be assigned a value that has already been assigned to another cell +- When playing, a cell can be marked as selected + +# Refactoring + +There are several implementations you can use to practice refactoring in this repo: [Bingo-Refactoring-Kata](https://github.com/sammancoaching/Bingo-Refactoring-Kata). + +Various aspects of parallel change can be highlighted: + +- Swapping the internal data structure (introducing Cell[][]) +- Introducing Coordinate and using it as parameter type. This one would affect the API (method signature) and so we have external dependencies on the “old” API which we should preserve in parallel with the new one. In a real system you’d use Parallel Change to eventually remove the “old” API once all the clients were migrated to the new one. + +# Notes + +All tests exist twice, one more technically oriented, one more professionally oriented (BDD), please use the one that suits you better. + +## Acknowledgement + +This kata was first published elsewhere: [Bingo Refactoring Kata](https://github.com/atruvia/samman-coaching-katas/tree/master/bingo-refactoring-kata) From 2efbc3e546643c7b946dca39432f1c2b7ed2f8b6 Mon Sep 17 00:00:00 2001 From: "Peter Fichtner (pfichtner)" Date: Fri, 31 May 2024 16:23:21 +0200 Subject: [PATCH 2/3] header font size decreased --- _kata_descriptions/bingo.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/_kata_descriptions/bingo.md b/_kata_descriptions/bingo.md index 1391562..7ce0f66 100644 --- a/_kata_descriptions/bingo.md +++ b/_kata_descriptions/bingo.md @@ -20,7 +20,7 @@ The business rules are: - A cell may not be assigned a value that has already been assigned to another cell - When playing, a cell can be marked as selected -# Refactoring +## Refactoring There are several implementations you can use to practice refactoring in this repo: [Bingo-Refactoring-Kata](https://github.com/sammancoaching/Bingo-Refactoring-Kata). @@ -29,10 +29,10 @@ Various aspects of parallel change can be highlighted: - Swapping the internal data structure (introducing Cell[][]) - Introducing Coordinate and using it as parameter type. This one would affect the API (method signature) and so we have external dependencies on the “old” API which we should preserve in parallel with the new one. In a real system you’d use Parallel Change to eventually remove the “old” API once all the clients were migrated to the new one. -# Notes +## Notes All tests exist twice, one more technically oriented, one more professionally oriented (BDD), please use the one that suits you better. -## Acknowledgement +### Acknowledgement This kata was first published elsewhere: [Bingo Refactoring Kata](https://github.com/atruvia/samman-coaching-katas/tree/master/bingo-refactoring-kata) From 9fe482b9d0acade40b03f972556852677266e6cf Mon Sep 17 00:00:00 2001 From: "Peter Fichtner (pfichtner)" Date: Fri, 7 Jun 2024 16:42:32 +0200 Subject: [PATCH 3/3] filler word added --- _kata_descriptions/bingo.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_kata_descriptions/bingo.md b/_kata_descriptions/bingo.md index 7ce0f66..26177b7 100644 --- a/_kata_descriptions/bingo.md +++ b/_kata_descriptions/bingo.md @@ -13,7 +13,7 @@ This kata is used for practicing refactoring. The code contains at least the cod - long methods The structure of the Bingo Refactoring Kata is similar to the Game of Life kata, but since the focus here is on refactoring, the business rules should be kept as simple as possible. It is not absolutely necessary to understand the business rules in order to complete the task. -The business rules are: +However, the business rules are: - A bingo board must be initialized before it can be used/played - A board is initialized when each cell has been assigned a value