mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-24 22:32:06 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			15 lines
		
	
	
	
		
			297 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			15 lines
		
	
	
	
		
			297 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
| test("basic functionality", () => {
 | |
|     let a = [];
 | |
|     for (let i = 0; i < 3; ++i) {
 | |
|         a.push(i);
 | |
|     }
 | |
|     expect(a).toEqual([0, 1, 2]);
 | |
| });
 | |
| 
 | |
| test("only condition", () => {
 | |
|     let a = [];
 | |
|     for (; a.length < 3; ) {
 | |
|         a.push("x");
 | |
|     }
 | |
|     expect(a).toEqual(["x", "x", "x"]);
 | |
| });
 | 
