Skip to content

Commit 4609356

Browse files
authored
chore: Add test for std.removeAt which should not modify the parameter. (#437)
Motivation: Add a test for std.removeAt, which should not modify the parameter. ported from go-jsonnet refs: google/go-jsonnet#812
1 parent 63d5357 commit 4609356

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
[
2+
"quux",
3+
"foo",
4+
"bar",
5+
"foo",
6+
"bar"
7+
]
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
local a = ['quux','foo','bar'];
2+
local b = std.removeAt(a,0);
3+
a+b

0 commit comments

Comments
 (0)