Skip to content

Commit 1618ee4

Browse files
jcs-instructornitsanavni4dsherwoodkevinmaesmander11
committed
. t Fizz rule in DB test
Co-Authored-By: Nitsan Avni <nitsanav@gmail.com> Co-Authored-By: Joel Silberman <42779942+jcs-instructor@users.noreply.github.com> Co-Authored-By: 4dsherwood <4dsherwood@users.noreply.github.com> Co-Authored-By: Kevin Maes <kevin@kevinmaes.com> Co-Authored-By: Matt <matthew.anderson11@gmail.com>
1 parent 7aece67 commit 1618ee4

File tree

2 files changed

+33
-0
lines changed

2 files changed

+33
-0
lines changed

katas/fizzbuzz/test_fizzbuzz.py

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,15 @@ def test_example_using_mock_db(mock_mongo_client):
1313
result = collection.find_one({"name": "John"})
1414

1515
assert result["age"] == 30
16+
17+
def test_have_fizz_buzz_specs_in_DB(mock_mongo_client):
18+
db = mock_mongo_client.mydatabase
19+
collection = db.ourcollection
20+
21+
# input: 9
22+
# output: fizz
23+
# denominator: 3
24+
collection.insert_one({"word": "Fizz", "denominator": 3})
25+
result = collection.find_one({"word": "Fizz"})
26+
27+
assert result["denominator"] == 3

session-notes/session-notes-2024-04-18.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,27 @@ Joel
7878

7979
### Mid-Session Retro 2 (1 minute per person - what liked/disliked & propose changes)
8080

81+
Joel
82+
- Enjoyed it! Interesting conversation, and getting on same page, uncharted territory
83+
- Liked: taking a dummy test -> changing the fields -> just worked
84+
- Still interested to see how this goes
85+
86+
Diana
87+
- Working well
88+
- Appreciate talking through the different representations, talking about it made it clearer to see the differences
89+
- As Typist did not see it clearly
90+
- Tests helped reveal that
91+
- Excited about using a DB
92+
- propose to commit soon
93+
94+
Nitsan
95+
- Very interesting - PO discussion; where is the responsibility of who?
96+
- Representing something in DB but usually isn't something a PO cares about
97+
- Up to tech and non-tech people to have an understanding of the domain
98+
- Nice to have DB represent domain to avoid confusion; so not solely a tech concern
99+
- Not sure what answer is; instinct: PO shouldn't tell tech what the internals should be, but good to be part of discussion
100+
101+
81102
### Final Retro
82103

83104
### How we spent our time today:

0 commit comments

Comments
 (0)