mirror of
				https://github.com/tc39/test262.git
				synced 2025-10-31 11:44:31 +01:00 
			
		
		
		
	Update tests for DataView & resizable Arraybuffer
This change concerns normative text of the Resizable ArrayBuffer proposal which is believed to be invalid in its current form; a patch updating the text is under review [1]. [1] https://github.com/tc39/proposal-resizablearraybuffer/pull/78
This commit is contained in:
		
							parent
							
								
									fcaa7594a4
								
							
						
					
					
						commit
						09485d387f
					
				| @ -36,6 +36,13 @@ assert.sameValue(dataView.byteLength, expected, "following shrink (within bounds | ||||
| 
 | ||||
| try { | ||||
|   ab.resize(1); | ||||
|   expected = 0; | ||||
| } catch (_) {} | ||||
| 
 | ||||
| assert.sameValue(dataView.byteLength, expected, "following shrink (on boundary)"); | ||||
| 
 | ||||
| try { | ||||
|   ab.resize(0); | ||||
|   expected = TypeError; | ||||
| } catch (_) { | ||||
|   expected = Test262Error; | ||||
|  | ||||
| @ -31,9 +31,15 @@ try { | ||||
| 
 | ||||
| assert.sameValue(dataView.byteOffset, 1, "following shrink (within bounds)"); | ||||
| 
 | ||||
| var expectedError; | ||||
| try { | ||||
|   ab.resize(1); | ||||
| } catch (_) {} | ||||
| 
 | ||||
| assert.sameValue(dataView.byteOffset, 1, "following shrink (on boundary)"); | ||||
| 
 | ||||
| var expectedError; | ||||
| try { | ||||
|   ab.resize(0); | ||||
|   expectedError = TypeError; | ||||
| } catch (_) { | ||||
|   expectedError = Test262Error; | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user