Changes related to the order of Skylark dictionaries:
- Objects of different types can now be compared.
- Printer now prints dictionaries in a deterministic order, even when the keys have different types.
- testEval() in EvaluationTestCases evaluates both expressions instead of comparing expression strings. Consequently, if a statement describes a collection, its order does no longer matter when doing the comparison.
--
MOS_MIGRATED_REVID=99829458
diff --git a/src/test/java/com/google/devtools/build/lib/syntax/EvaluationTest.java b/src/test/java/com/google/devtools/build/lib/syntax/EvaluationTest.java
index 9b0ce0b..14988cb 100644
--- a/src/test/java/com/google/devtools/build/lib/syntax/EvaluationTest.java
+++ b/src/test/java/com/google/devtools/build/lib/syntax/EvaluationTest.java
@@ -218,15 +218,7 @@
.testStatement("('a', 'b') <= ('a', 'b')", true)
.testStatement("[[1, 1]] > [[1, 1], []]", false)
- .testStatement("[[1, 1]] < [[1, 1], []]", true)
-
- .testIfExactError("Cannot compare int with string", "[1] < ['a']")
- .testIfExactError("Cannot compare list with int", "[1] < 1");
- }
-
- @Test
- public void testCompareStringInt() throws Exception {
- newTest().testIfExactError("Cannot compare string with int", "'a' >= 1");
+ .testStatement("[[1, 1]] < [[1, 1], []]", true);
}
@Test