File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -101,7 +101,27 @@ def test_green_with_live_t1_promotes():
101101 band = "green" , source_urls = ["https://en.wikipedia.org/wiki/X" ],
102102 url_cache = cache , crossref_decision = None ,
103103 )
104- assert d .promote and d .reason == "green+live-t1"
104+ assert d .promote and d .reason == "green+live-source"
105+
106+
107+ def test_green_with_live_t2_promotes ():
108+ # A reputable T2 spec/benchmark DB (cpubenchmark) that is alive also promotes.
109+ cache = {"https://www.cpubenchmark.net/cpu.php?id=1" : {"alive" : True }}
110+ d = promote .decide (
111+ band = "green" , source_urls = ["https://www.cpubenchmark.net/cpu.php?id=1" ],
112+ url_cache = cache , crossref_decision = None ,
113+ )
114+ assert d .promote and d .reason == "green+live-source"
115+
116+
117+ def test_green_with_only_t3_source_held ():
118+ # kaggle (T3) alive is NOT enough to promote even if green.
119+ cache = {"https://www.kaggle.com/x" : {"alive" : True }}
120+ d = promote .decide (
121+ band = "green" , source_urls = ["https://www.kaggle.com/x" ],
122+ url_cache = cache , crossref_decision = None ,
123+ )
124+ assert not d .promote
105125
106126
107127def test_green_without_live_source_blocked ():
You can’t perform that action at this time.
0 commit comments