Răsfoiți Sursa

added test for #4142

Nicolas Cannasse 10 ani în urmă
părinte
comite
c829fa1bcb
1 a modificat fișierele cu 6 adăugiri și 0 ștergeri
  1. 6 0
      tests/unit/src/unitstd/haxe/io/UInt8Array.unit.hx

+ 6 - 0
tests/unit/src/unitstd/haxe/io/UInt8Array.unit.hx

@@ -79,3 +79,9 @@ for( i in 0...3 )
 b3[0] = b3[0] + 1;
 if( !emulated ) b3[0] == b[2];
 
+var bytes = haxe.io.Bytes.alloc(50);
+var b4 = haxe.io.UInt8Array.fromBytes(bytes);
+b4.length == 50;
+b4.set(0,55);
+b4.get(0) == 55;
+if( !emulated ) bytes.get(0) == 55;