Skip to content

Commit

Permalink
4 new methods (#21)
Browse files Browse the repository at this point in the history
* feat : ristretto method added

* feat : lungo method added

* feat : turkish method added

* feat : cupping method added

* fix : tests updated

* fix : tests updated

* doc : CHANGELOG.md updated

* doc : METHODS.md updated

* doc : references section updated
  • Loading branch information
sepandhaghighi authored Sep 21, 2024
1 parent 5e67c0b commit a3c44c7
Show file tree
Hide file tree
Showing 6 changed files with 121 additions and 14 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
## [Unreleased]
### Added
- Logo
- 4 new methods
1. Ristretto
2. Lungo
3. Turkish
4. Cupping
## [0.2] - 2024-09-17
### Added
- 5 new methods
Expand Down
28 changes: 28 additions & 0 deletions METHODS.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,34 @@
<td>60</td>
<td>>=0.2</td>
</tr>
<tr align="center">
<td>Ristretto</td>
<td><code>ristretto</code></td>
<td>1/1</td>
<td>18</td>
<td>>=0.3</td>
</tr>
<tr align="center">
<td>Lungo</td>
<td><code>lungo</code></td>
<td>1/4</td>
<td>72</td>
<td>>=0.3</td>
</tr>
<tr align="center">
<td>Turkish</td>
<td><code>turkish</code></td>
<td>1/10</td>
<td>50</td>
<td>>=0.3</td>
</tr>
<tr align="center">
<td>Cupping</td>
<td><code>cupping</code></td>
<td>11/200</td>
<td>150</td>
<td>>=0.3</td>
</tr>
</table>


2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,8 @@ Just fill an issue and describe it. We'll check it ASAP!
<blockquote>9- <a href="https://counterculturecoffee.com/blogs/counter-culture-coffee/guide-to-cold-brew">Guide To Cold Brew</a></blockquote>
<blockquote>10- <a href="https://www.thespruceeats.com/cold-brew-concentrate-recipe-5197494">Cold Brew Concentrate Recipe</a></blockquote>
<blockquote>11- <a href="https://bakedbrewedbeautiful.com/how-to-make-coffee-in-moka-pot/">How to Make Coffee in a Moka Pot</a></blockquote>
<blockquote>12- <a href="https://www.drinktrade.com/blogs/education/how-to-make-turkish-coffee">How to Make Turkish Coffee at Home</a></blockquote>
<blockquote>13- <a href="https://www.horshamcoffeeroaster.co.uk/pages/how-to-cup-coffee">How to Cup Coffee</a></blockquote>

## Show Your Support
Expand Down
24 changes: 24 additions & 0 deletions mycoffee/params.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,18 @@
"water": 36,
"info": "Espresso method"
},
"ristretto": {
"coffee_ratio": 1,
"water_ratio": 1,
"water": 18,
"info": "Ristretto method"
},
"lungo": {
"coffee_ratio": 1,
"water_ratio": 4,
"water": 72,
"info": "Lungo method"
},
"chemex": {
"coffee_ratio": 1,
"water_ratio": 15,
Expand Down Expand Up @@ -99,5 +111,17 @@
"water_ratio": 10,
"water": 60,
"info": "Moka pot method"
},
"turkish": {
"coffee_ratio": 1,
"water_ratio": 10,
"water": 50,
"info": "Turkish method"
},
"cupping": {
"coffee_ratio": 11,
"water_ratio": 200,
"water": 150,
"info": "Cupping method"
}
}
36 changes: 22 additions & 14 deletions test/functions_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,17 @@
2. `chemex` - Chemex method
3. `cold-brew` - Cold brew method
4. `cold-brew-conc` - Cold brew concentrate method
5. `custom` - Custom brewing method
6. `espresso` - Espresso method
7. `french-press` - French press method
8. `moka-pot` - Moka pot method
9. `pour-over` - Pour-over method
10. `siphon` - Siphon method
11. `v60` - V60 method
5. `cupping` - Cupping method
6. `custom` - Custom brewing method
7. `espresso` - Espresso method
8. `french-press` - French press method
9. `lungo` - Lungo method
10. `moka-pot` - Moka pot method
11. `pour-over` - Pour-over method
12. `ristretto` - Ristretto method
13. `siphon` - Siphon method
14. `turkish` - Turkish method
15. `v60` - V60 method
>>> test_params = {"method":"v60", "cups":2, "coffee":30, "water":335, "coffee_ratio": 3, "water_ratio":50, "info":"V60 method"}
>>> calc_coffee(test_params)
20.1
Expand Down Expand Up @@ -156,11 +160,15 @@
2. `chemex` - Chemex method
3. `cold-brew` - Cold brew method
4. `cold-brew-conc` - Cold brew concentrate method
5. `custom` - Custom brewing method
6. `espresso` - Espresso method
7. `french-press` - French press method
8. `moka-pot` - Moka pot method
9. `pour-over` - Pour-over method
10. `siphon` - Siphon method
11. `v60` - V60 method
5. `cupping` - Cupping method
6. `custom` - Custom brewing method
7. `espresso` - Espresso method
8. `french-press` - French press method
9. `lungo` - Lungo method
10. `moka-pot` - Moka pot method
11. `pour-over` - Pour-over method
12. `ristretto` - Ristretto method
13. `siphon` - Siphon method
14. `turkish` - Turkish method
15. `v60` - V60 method
"""
40 changes: 40 additions & 0 deletions test/verified_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,4 +101,44 @@
>>> moka_pot_coffee = calc_coffee(moka_pot_params)
>>> moka_pot_coffee == 6
True
>>> ristretto_params = load_method_params("ristretto") # https://honestcoffeeguide.com/coffee-to-water-ratio-calculator
>>> ristretto_params["coffee_ratio"] == 1
True
>>> ristretto_params["water_ratio"] == 1
True
>>> ristretto_params["water"] == 18
True
>>> ristretto_coffee = calc_coffee(ristretto_params)
>>> ristretto_coffee == 18
True
>>> lungo_params = load_method_params("lungo") # https://honestcoffeeguide.com/coffee-to-water-ratio-calculator
>>> lungo_params["coffee_ratio"] == 1
True
>>> lungo_params["water_ratio"] == 4
True
>>> lungo_params["water"] == 72
True
>>> lungo_coffee = calc_coffee(lungo_params)
>>> lungo_coffee == 18
True
>>> turkish_params = load_method_params("turkish") # https://www.drinktrade.com/blogs/education/how-to-make-turkish-coffee
>>> turkish_params["coffee_ratio"] == 1
True
>>> turkish_params["water_ratio"] == 10
True
>>> turkish_params["water"] == 50
True
>>> turkish_coffee = calc_coffee(turkish_params)
>>> turkish_coffee == 5
True
>>> cupping_params = load_method_params("cupping") # https://www.horshamcoffeeroaster.co.uk/pages/how-to-cup-coffee
>>> cupping_params["coffee_ratio"] == 11
True
>>> cupping_params["water_ratio"] == 200
True
>>> cupping_params["water"] == 150
True
>>> cupping_coffee = calc_coffee(cupping_params)
>>> cupping_coffee == 8.25
True
"""

0 comments on commit a3c44c7

Please sign in to comment.