Skip to content

Commit

Permalink
5 new methods (#8)
Browse files Browse the repository at this point in the history
* feat : 5 new methods added

* fix : tests updated

* fix : tests updated

* fix : minor edit in functions test

* doc : METHODS.md updated

* doc : CHANGELOG.md updated

* fix : minor edit in cold-brew-conc info

* doc : references updated
  • Loading branch information
sepandhaghighi authored Sep 3, 2024
1 parent 12f16cf commit b07e052
Show file tree
Hide file tree
Showing 6 changed files with 149 additions and 12 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,13 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).

## [Unreleased]
### Added
- 5 new methods
1. Pour-over
2. Auto drip
3. Cold brew
4. Cold brew concentrate
5. Moka pot
## [0.1] - 2024-09-02
### Added
- 6 new methods
Expand Down
35 changes: 35 additions & 0 deletions METHODS.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,41 @@
<td>240</td>
<td>>=0.1</td>
</tr>
<tr align="center">
<td>Pour-over</td>
<td><code>pour-over</code></td>
<td>1/15</td>
<td>240</td>
<td>>=0.2</td>
</tr>
<tr align="center">
<td>Auto drip</td>
<td><code>auto-drip</code></td>
<td>1/16</td>
<td>128</td>
<td>>=0.2</td>
</tr>
<tr align="center">
<td>Cold brew</td>
<td><code>cold-brew</code></td>
<td>1/11</td>
<td>242</td>
<td>>=0.2</td>
</tr>
<tr align="center">
<td>Cold brew concentrate</td>
<td><code>cold-brew-conc</code></td>
<td>1/5</td>
<td>120</td>
<td>>=0.2</td>
</tr>
<tr align="center">
<td>Moka pot</td>
<td><code>moka-pot</code></td>
<td>1/10</td>
<td>60</td>
<td>>=0.2</td>
</tr>
</table>


5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,11 @@ Just fill an issue and describe it. We'll check it ASAP!
<blockquote>4- <a href="https://www.illy.com/en-us/coffee/coffee-preparation/how-to-use-a-french-press">Using French press for perfect coffee</a></blockquote>
<blockquote>5- <a href="https://www.haymancoffee.com/blogs/coffee-blog/how-to-brew-the-perfect-cup-of-siphon-coffee">How to Brew the Perfect Cup of Siphon Coffee</a></blockquote>
<blockquote>6- <a href="https://home.lamarzoccousa.com/using-espresso-brew-ratios/">Using Espresso Brew Ratios</a></blockquote>
<blockquote>7- <a href="https://www.nicolebattefeld.com/post/best-recipes-2022">My Best Coffee Recipes of 2022</a></blockquote>
<blockquote>8- <a href="https://wonderstate.com/pages/auto-drip">Auto Drip Brewing Guide</a></blockquote>
<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>

## Show Your Support
Expand Down
30 changes: 30 additions & 0 deletions mycoffee/params.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,5 +68,35 @@
"water_ratio": 15,
"water": 240,
"info": "Siphon method"
},
"pour-over": {
"coffee_ratio": 1,
"water_ratio": 15,
"water": 240,
"info": "Pour-over method"
},
"auto-drip": {
"coffee_ratio": 1,
"water_ratio": 16,
"water": 128,
"info": "Auto drip method"
},
"cold-brew": {
"coffee_ratio": 1,
"water_ratio": 11,
"water": 242,
"info": "Cold brew method"
},
"cold-brew-conc": {
"coffee_ratio": 1,
"water_ratio": 5,
"water": 120,
"info": "Cold brew concentrate method"
},
"moka-pot": {
"coffee_ratio": 1,
"water_ratio": 10,
"water": 60,
"info": "Moka pot method"
}
}
34 changes: 22 additions & 12 deletions test/functions_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,17 @@
>>> show_methods_list()
Methods list:
<BLANKLINE>
1. `chemex` - Chemex method
2. `custom` - Custom brewing method
3. `espresso` - Espresso method
4. `french-press` - French press method
5. `siphon` - Siphon method
6. `v60` - V60 method
1. `auto-drip` - Auto drip method
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
>>> test_params = {"method":"v60", "cups":2, "coffee":30, "water":335, "coffee_ratio": 3, "water_ratio":50, "info":"V60 method"}
>>> coffee_calc(test_params)
20.1
Expand Down Expand Up @@ -110,10 +115,15 @@
>>> run(args)
Methods list:
<BLANKLINE>
1. `chemex` - Chemex method
2. `custom` - Custom brewing method
3. `espresso` - Espresso method
4. `french-press` - French press method
5. `siphon` - Siphon method
6. `v60` - V60 method
1. `auto-drip` - Auto drip method
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
"""
50 changes: 50 additions & 0 deletions test/verified_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,4 +51,54 @@
>>> french_press_coffee = coffee_calc(french_press_params)
>>> french_press_coffee == 8
True
>>> pour_over_params = load_method_params("pour-over") # https://www.nicolebattefeld.com/post/best-recipes-2022
>>> pour_over_params["coffee_ratio"] == 1
True
>>> pour_over_params["water_ratio"] == 15
True
>>> pour_over_params["water"] == 240
True
>>> pour_over_coffee = coffee_calc(pour_over_params)
>>> pour_over_coffee == 16
True
>>> auto_drip_params = load_method_params("auto-drip") # https://wonderstate.com/pages/auto-drip
>>> auto_drip_params["coffee_ratio"] == 1
True
>>> auto_drip_params["water_ratio"] == 16
True
>>> auto_drip_params["water"] == 128
True
>>> auto_drip_coffee = coffee_calc(auto_drip_params)
>>> auto_drip_coffee == 8
True
>>> cold_brew_params = load_method_params("cold-brew") # https://counterculturecoffee.com/blogs/counter-culture-coffee/guide-to-cold-brew
>>> cold_brew_params["coffee_ratio"] == 1
True
>>> cold_brew_params["water_ratio"] == 11
True
>>> cold_brew_params["water"] == 242
True
>>> cold_brew_coffee = coffee_calc(cold_brew_params)
>>> cold_brew_coffee == 22
True
>>> cold_brew_conc_params = load_method_params("cold-brew-conc") # https://www.thespruceeats.com/cold-brew-concentrate-recipe-5197494
>>> cold_brew_conc_params["coffee_ratio"] == 1
True
>>> cold_brew_conc_params["water_ratio"] == 5
True
>>> cold_brew_conc_params["water"] == 120
True
>>> cold_brew_conc_coffee = coffee_calc(cold_brew_conc_params)
>>> cold_brew_conc_coffee == 24
True
>>> moka_pot_params = load_method_params("moka-pot") # https://bakedbrewedbeautiful.com/how-to-make-coffee-in-moka-pot
>>> moka_pot_params["coffee_ratio"] == 1
True
>>> moka_pot_params["water_ratio"] == 10
True
>>> moka_pot_params["water"] == 60
True
>>> moka_pot_coffee = coffee_calc(moka_pot_params)
>>> moka_pot_coffee == 6
True
"""

0 comments on commit b07e052

Please sign in to comment.