Castle: The best Real-Time/Embedded/HighTech language EVER. Attempt 2
修订版 | 18eb6ff53f92f3b239538ec666eeb26c305ccf7b (tree) |
---|---|
时间 | 2023-10-11 04:51:30 |
作者 | Albert Mietus < albert AT mietus DOT nl > |
Commiter | Albert Mietus < albert AT mietus DOT nl > |
(re)Added ConsecutiveSeries test for ProtocolKind, to remove surviving mutants
@@ -14,3 +14,12 @@ | ||
14 | 14 | assert ProtocolKind.Event |
15 | 15 | assert ProtocolKind.Data |
16 | 16 | assert ProtocolKind.Stream |
17 | + | |
18 | +def test_2_ConsecutiveSeries(): | |
19 | + values = sorted(k.value for k in ProtocolKind) | |
20 | + v1 = values[0] | |
21 | + for v2 in values[1:]: | |
22 | + assert v1+1==v2, f"{ProtocolKind(v1)}+1 <> {ProtocolKind(v2)}" | |
23 | + v1=v2 | |
24 | + | |
25 | + |