@@ -376,14 +376,14 @@ module DynamoToStructTest {
376
376
// = type=test
377
377
// # Entries in a String Set MUST be ordered in ascending [UTF-16 binary order](./string-ordering.md#utf-16-binary-order).
378
378
method {:test} TestSortSSAttr () {
379
- var stringSetValue := AttributeValue. SS (["&","。","𐀂 "]);
379
+ var stringSetValue := AttributeValue. SS (["&","。","\ud800\udc02 "]);
380
380
// Note that string values are UTF-8 encoded, but sorted by UTF-16 encoding.
381
381
var encodedStringSetData := StructuredDataTerminal (value := [
382
382
0,0,0,3, // 3 entries in set
383
383
0,0,0,1, // 1st entry is 1 byte
384
384
0x26, // "&" in UTF-8 encoding
385
385
0,0,0,4, // 2nd entry is 4 bytes
386
- 0xF0,0x90,0x80,0x82, // "𐀂 " in UTF-8 encoding
386
+ 0xF0,0x90,0x80,0x82, // "\ud800\udc02 " in UTF-8 encoding
387
387
0,0,0,3, // 3rd entry is 3 bytes
388
388
0xEF,0xBD,0xA1 // "。" in UTF-8 encoding
389
389
],
@@ -395,7 +395,7 @@ module DynamoToStructTest {
395
395
396
396
var newStringSetValue := StructuredToAttr (encodedStringSetData);
397
397
expect newStringSetValue. Success?;
398
- expect newStringSetValue. value == AttributeValue. SS (["&","𐀂 ","。"]);
398
+ expect newStringSetValue. value == AttributeValue. SS (["&","\ud800\udc02 ","。"]);
399
399
}
400
400
401
401
// = specification/dynamodb-encryption-client/ddb-attribute-serialization.md#set-entries
@@ -415,11 +415,11 @@ module DynamoToStructTest {
415
415
416
416
method {:test} TestSetsInListAreSorted () {
417
417
var nSetValue := AttributeValue. NS (["2","1","10"]);
418
- var sSetValue := AttributeValue. SS (["&","。","𐀂 "]);
418
+ var sSetValue := AttributeValue. SS (["&","。","\ud800\udc02 "]);
419
419
var bSetValue := AttributeValue. BS ([[1,0],[1],[2]]);
420
420
421
421
var sortedNSetValue := AttributeValue. NS (["1","10","2"]);
422
- var sortedSSetValue := AttributeValue. SS (["&","𐀂 ","。"]);
422
+ var sortedSSetValue := AttributeValue. SS (["&","\ud800\udc02 ","。"]);
423
423
var sortedBSetValue := AttributeValue. BS ([[1],[1,0],[2]]);
424
424
425
425
var listValue := AttributeValue. L ([nSetValue, sSetValue, bSetValue]);
@@ -444,11 +444,11 @@ module DynamoToStructTest {
444
444
445
445
method {:test} TestSetsInMapAreSorted () {
446
446
var nSetValue := AttributeValue. NS (["2","1","10"]);
447
- var sSetValue := AttributeValue. SS (["&","。","𐀂 "]);
447
+ var sSetValue := AttributeValue. SS (["&","。","\ud800\udc02 "]);
448
448
var bSetValue := AttributeValue. BS ([[1,0],[1],[2]]);
449
449
450
450
var sortedNSetValue := AttributeValue. NS (["1","10","2"]);
451
- var sortedSSetValue := AttributeValue. SS (["&","𐀂 ","。"]);
451
+ var sortedSSetValue := AttributeValue. SS (["&","\ud800\udc02 ","。"]);
452
452
var sortedBSetValue := AttributeValue. BS ([[1],[1,0],[2]]);
453
453
454
454
var mapValue := AttributeValue. M (map["keyA" := sSetValue, "keyB" := nSetValue, "keyC" := bSetValue]);
@@ -490,7 +490,7 @@ module DynamoToStructTest {
490
490
method {:test} TestSortMapKeys () {
491
491
var nullValue := AttributeValue. NULL (true);
492
492
493
- var mapValue := AttributeValue. M (map["&" := nullValue, "。" := nullValue, "𐀂 " := nullValue]);
493
+ var mapValue := AttributeValue. M (map["&" := nullValue, "。" := nullValue, "\ud800\udc02 " := nullValue]);
494
494
495
495
// Note that the string values are encoded as UTF-8, but are sorted according to UTF-16 encoding.
496
496
var encodedMapData := StructuredDataTerminal (
@@ -500,7 +500,7 @@ module DynamoToStructTest {
500
500
0x26, // "&" UTF-8 encoded
501
501
0,0, 0,0,0,0, // null value
502
502
0,1, 0,0,0,4, // 2nd key is a string 4 bytes long
503
- 0xF0, 0x90, 0x80, 0x82, // "𐀂 " UTF-8 encoded
503
+ 0xF0, 0x90, 0x80, 0x82, // "\ud800\udc02 " UTF-8 encoded
504
504
0,0, 0,0,0,0, // null value
505
505
0,1, 0,0,0,3, // 3rd key is a string 3 bytes long
506
506
0xEF, 0xBD, 0xA1, // "。"
0 commit comments