Lines Matching refs:s1
10 let s1 = new Stack();
11 assertSame(Stack.prototype, s1.__proto__);
12 assertTrue(Array.isArray(s1));
13 assertSame(0, s1.length);
14 s1[0] = 'xyz';
15 assertSame(1, s1.length);
16 assertSame('xyz', s1[0]);
17 s1.push(42);
18 assertSame(2, s1.length);
19 assertSame('xyz', s1[0]);
20 assertSame(42, s1[1]);
66 let s1 = new Stack();
67 assertSame(Stack.prototype, s1.__proto__);
68 assertTrue(Array.isArray(s1));
69 assertSame(0, s1.length);
70 s1[0] = 'xyz';
71 assertSame(1, s1.length);
72 assertSame('xyz', s1[0]);
73 s1.push(42);
74 assertSame(2, s1.length);
75 assertSame('xyz', s1[0]);
76 assertSame(42, s1[1]);
137 let s1 = new Stack(1,2,3);
139 assertArrayEquals([1,2,3,4,5,6], s1.concat([4,5,6]));
140 assertArrayEquals([4,5,6,1,2,3], [4,5,6].concat(s1));
147 let s1 = new Stack(1,2,3);
148 assertSame("[1,2,3]", JSON.stringify(s1));