diff options
Diffstat (limited to 'src/test/java/com/google/devtools/build/lib/syntax')
-rw-r--r-- | src/test/java/com/google/devtools/build/lib/syntax/SkylarkEvaluationTest.java | 34 |
1 files changed, 3 insertions, 31 deletions
diff --git a/src/test/java/com/google/devtools/build/lib/syntax/SkylarkEvaluationTest.java b/src/test/java/com/google/devtools/build/lib/syntax/SkylarkEvaluationTest.java index c7cc34805d..8aaeb88b00 100644 --- a/src/test/java/com/google/devtools/build/lib/syntax/SkylarkEvaluationTest.java +++ b/src/test/java/com/google/devtools/build/lib/syntax/SkylarkEvaluationTest.java @@ -1074,21 +1074,8 @@ public class SkylarkEvaluationTest extends EvaluationTest { } @Test - public void testPlusEqualsOnListCopying() throws Exception { - new SkylarkTest("--incompatible_list_plus_equals_inplace=false") - .setUp( - "def func():", - " l1 = [1, 2]", - " l2 = l1", - " l2 += [3, 4]", - " return l1, l2", - "lists = str(func())") - .testLookup("lists", "([1, 2], [1, 2, 3, 4])"); - } - - @Test public void testPlusEqualsOnListMutating() throws Exception { - new SkylarkTest("--incompatible_list_plus_equals_inplace=true") + new SkylarkTest() .setUp( "def func():", " l1 = [1, 2]", @@ -1099,7 +1086,7 @@ public class SkylarkEvaluationTest extends EvaluationTest { .testLookup("lists", "([1, 2, 3, 4], [1, 2, 3, 4])"); // The same but with += after an IndexExpression - new SkylarkTest("--incompatible_list_plus_equals_inplace=true") + new SkylarkTest() .setUp( "def func():", " l = [1, 2]", @@ -1112,22 +1099,7 @@ public class SkylarkEvaluationTest extends EvaluationTest { @Test public void testPlusEqualsOnTuple() throws Exception { - new SkylarkTest("--incompatible_list_plus_equals_inplace=false") - .setUp( - "def func():", - " t1 = (1, 2)", - " t2 = t1", - " t2 += (3, 4)", - " return t1, t2", - "tuples = func()") - .testLookup("tuples", SkylarkList.Tuple.of( - SkylarkList.Tuple.of(1, 2), - SkylarkList.Tuple.of(1, 2, 3, 4) - )); - - // This behavior should remain the same regardless of the - // --incompatible_list_plus_equals_inplace flag - new SkylarkTest("--incompatible_list_plus_equals_inplace=true") + new SkylarkTest() .setUp( "def func():", " t1 = (1, 2)", |