Merge remote-tracking branch 'origin/main' into feat/region-seo-pages
# Conflicts: # frontend/src/b/BLayout.tsx
This commit is contained in:
commit
2ca060b626
6 files changed
+196
-9
No files matched your search
@@ -308,3 +308,13 @@ def test_humidity_cap():
|
||||
|
||||
def test_axis_label_can_be_overridden():
|
||||
assert axis_label("temp", {"temp": {"type": "higher", "label": "덜 추움"}}) == "덜 추움"
|
||||
|
||||
|
||||
def test_umbrella_lost_needs_rain_that_stopped():
|
||||
"""우산분실각: 앞서 비가 왔다가 그친 시간대만 점수가 난다. 비가 안 온 날, 아직 비가 오는 시간대는 0점."""
|
||||
defn = _defn(weight_temp=0, weight_rain=80, weight_wind=0, weight_humidity=0, weight_air=0, weight_time=20,
|
||||
zero_rules=[{"field": "rain_before", "op": "==", "value": "no"}, {"field": "rain", "op": "==", "value": "yes"}])
|
||||
after_rain = replace(CTX, rain_hours=frozenset({9, 10}))
|
||||
assert evaluate(defn, [[_h(13), _h(14)]], after_rain).score >= 80
|
||||
assert evaluate(defn, [[_h(13), _h(14)]], CTX).zero_reason == "앞서 내린 비가 없어 0점"
|
||||
assert evaluate(defn, [[_h(10, rain=RainType.RAIN)]], replace(CTX, rain_hours=frozenset({9, 10}))).score == 0
|
||||
Reference in new issue
Block a user