diff --git a/repository/BaselineOfSeaside3.package/.filetree b/repository/BaselineOfSeaside3.package/.filetree index 8998102c2..57a679737 100644 --- a/repository/BaselineOfSeaside3.package/.filetree +++ b/repository/BaselineOfSeaside3.package/.filetree @@ -1,4 +1,5 @@ { - "noMethodMetaData" : true, "separateMethodMetaAndSource" : false, - "useCypressPropertiesFile" : true } + "noMethodMetaData" : true, + "useCypressPropertiesFile" : true +} \ No newline at end of file diff --git a/repository/BaselineOfSeaside3.package/BaselineOfSeaside3.class/instance/baselinejson..st b/repository/BaselineOfSeaside3.package/BaselineOfSeaside3.class/instance/baselinejson..st index 4d72a6197..46619d7b5 100644 --- a/repository/BaselineOfSeaside3.package/BaselineOfSeaside3.class/instance/baselinejson..st +++ b/repository/BaselineOfSeaside3.package/BaselineOfSeaside3.class/instance/baselinejson..st @@ -27,13 +27,6 @@ baselinejson: spec package: 'Seaside-Tests-Pharo-JSON-Core' with: [ spec requires: #('Seaside-Tests-JSON') ] ]. - spec for: #'pharo7.x' do: [ - spec - package: 'Seaside-Pharo70-JSON-Extensions' with: [ spec requires: #('Seaside-JSON-Core') ]; - package: 'Seaside-Pharo-JSON-Core' with: [ spec includes: #('Seaside-Pharo70-JSON-Extensions') ]; - package: 'Seaside-Tests-Pharo70-JSON-Extensions'with: [ spec requires: #('Seaside-Tests-JSON') ]; - package: 'Seaside-Tests-Pharo-JSON-Core' with: [ spec includes: #('Seaside-Tests-Pharo70-JSON-Extensions') ] ]. - spec for: #'gemstone' do: [ diff --git a/repository/BaselineOfSeaside3.package/BaselineOfSeaside3.class/properties.json b/repository/BaselineOfSeaside3.package/BaselineOfSeaside3.class/properties.json index 3638c28e5..57540298c 100644 --- a/repository/BaselineOfSeaside3.package/BaselineOfSeaside3.class/properties.json +++ b/repository/BaselineOfSeaside3.package/BaselineOfSeaside3.class/properties.json @@ -1,14 +1,11 @@ { - "category" : "BaselineOfSeaside3", - "classinstvars" : [ - ], - "classvars" : [ - ], "commentStamp" : "", - "instvars" : [ - ], - "name" : "BaselineOfSeaside3", - "pools" : [ - ], "super" : "BaselineOf", - "type" : "normal" } + "category" : "BaselineOfSeaside3", + "classinstvars" : [ ], + "pools" : [ ], + "classvars" : [ ], + "instvars" : [ ], + "name" : "BaselineOfSeaside3", + "type" : "normal" +} \ No newline at end of file diff --git a/repository/BaselineOfSeaside3.package/monticello.meta/categories.st b/repository/BaselineOfSeaside3.package/monticello.meta/categories.st index 886c5b74e..33792de89 100644 --- a/repository/BaselineOfSeaside3.package/monticello.meta/categories.st +++ b/repository/BaselineOfSeaside3.package/monticello.meta/categories.st @@ -1 +1 @@ -SystemOrganization addCategory: #'BaselineOfSeaside3'! +SystemOrganization addCategory: #BaselineOfSeaside3! diff --git a/repository/BaselineOfSeaside3.package/properties.json b/repository/BaselineOfSeaside3.package/properties.json index f037444a7..6f31cf5a2 100644 --- a/repository/BaselineOfSeaside3.package/properties.json +++ b/repository/BaselineOfSeaside3.package/properties.json @@ -1,2 +1 @@ -{ - } +{ } \ No newline at end of file diff --git a/repository/Seaside-GemStone-JSON-Core.package/CharacterCollection.extension/instance/jsonKeyOn..st b/repository/Seaside-GemStone-JSON-Core.package/CharacterCollection.extension/instance/jsonKeyOn..st new file mode 100644 index 000000000..ae61bf0df --- /dev/null +++ b/repository/Seaside-GemStone-JSON-Core.package/CharacterCollection.extension/instance/jsonKeyOn..st @@ -0,0 +1,3 @@ +*seaside-gemstone-json-core +jsonKeyOn: aRenderer + self jsonOn: aRenderer \ No newline at end of file diff --git a/repository/Seaside-JSON-Core.package/Object.extension/instance/jsonKeyOn..st b/repository/Seaside-JSON-Core.package/Object.extension/instance/jsonKeyOn..st new file mode 100644 index 000000000..645b0adf8 --- /dev/null +++ b/repository/Seaside-JSON-Core.package/Object.extension/instance/jsonKeyOn..st @@ -0,0 +1,4 @@ +*Seaside-JSON-Core +jsonKeyOn: aRenderer + + self error: 'Only Strings can be used as keys in JSON objects.' \ No newline at end of file diff --git a/repository/Seaside-JSON-Core.package/String.extension/instance/jsonKeyOn..st b/repository/Seaside-JSON-Core.package/String.extension/instance/jsonKeyOn..st new file mode 100644 index 000000000..28e82203b --- /dev/null +++ b/repository/Seaside-JSON-Core.package/String.extension/instance/jsonKeyOn..st @@ -0,0 +1,3 @@ +*seaside-json-core +jsonKeyOn: aRenderer + self jsonOn: aRenderer \ No newline at end of file diff --git a/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/boolean..st b/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/boolean..st index 356793aae..6e86cca96 100644 --- a/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/boolean..st +++ b/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/boolean..st @@ -1,3 +1,3 @@ -double-disptach +double-dispatch boolean: aBoolean self document stream nextPutAll: (aBoolean ifTrue: [ 'true' ] ifFalse: [ 'false' ]) \ No newline at end of file diff --git a/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/dateAndTime..st b/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/dateAndTime..st index ea5ab383c..7e71d41ce 100644 --- a/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/dateAndTime..st +++ b/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/dateAndTime..st @@ -1,4 +1,4 @@ -double-disptach +double-dispatch dateAndTime: aDateAndTime " Note: date and time is not standard json. So we use the ISO 8601 standard here. We convert to string to make it valid json " self document stream nextPut: $". diff --git a/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/null.st b/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/null.st index 9737f4353..40bd328c1 100644 --- a/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/null.st +++ b/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/null.st @@ -1,3 +1,3 @@ -double-disptach +double-dispatch null self document stream nextPutAll: 'null' \ No newline at end of file diff --git a/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/number..st b/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/number..st index feeb5a9b1..c11195b7f 100644 --- a/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/number..st +++ b/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/number..st @@ -1,3 +1,3 @@ -double-disptach +double-dispatch number: aNumber aNumber printOn: self document stream \ No newline at end of file diff --git a/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/scaledDecimal..st b/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/scaledDecimal..st index 150106615..3183d96d3 100644 --- a/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/scaledDecimal..st +++ b/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/scaledDecimal..st @@ -1,4 +1,4 @@ -double-disptach +double-dispatch scaledDecimal: aScaledDecimal | converter | converter := GRSignPrinter new, (GRNumberPrinter new precision: aScaledDecimal scale). diff --git a/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/string..st b/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/string..st index 350a21919..6173e37fa 100644 --- a/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/string..st +++ b/repository/Seaside-JSON-Core.package/WAJsonCanvas.class/instance/string..st @@ -1,3 +1,3 @@ -double-disptach +double-dispatch string: aString self document string: aString \ No newline at end of file diff --git a/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/class/stringKeysOnly..st b/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/class/stringKeysOnly..st new file mode 100644 index 000000000..f5b2cde8f --- /dev/null +++ b/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/class/stringKeysOnly..st @@ -0,0 +1,3 @@ +accessing +stringKeysOnly: aBoolean + StringKeysOnly := aBoolean \ No newline at end of file diff --git a/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/class/stringKeysOnly.st b/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/class/stringKeysOnly.st new file mode 100644 index 000000000..d7614bba2 --- /dev/null +++ b/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/class/stringKeysOnly.st @@ -0,0 +1,3 @@ +accessing +stringKeysOnly + ^ StringKeysOnly ifNil: [ false ] \ No newline at end of file diff --git a/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/instance/openBrush.st b/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/instance/openBrush.st index 7d55f7b85..76817b57e 100644 --- a/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/instance/openBrush.st +++ b/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/instance/openBrush.st @@ -1,5 +1,7 @@ private openBrush super openBrush. - key jsonOn: canvas. + self class stringKeysOnly + ifTrue: [ key jsonKeyOn: canvas ] + ifFalse: [ key jsonOn: canvas ]. self document stream nextPutAll: ': ' \ No newline at end of file diff --git a/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/properties.json b/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/properties.json index 74b863fb1..41ab6bde9 100644 --- a/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/properties.json +++ b/repository/Seaside-JSON-Core.package/WAJsonKeyValueBrush.class/properties.json @@ -4,7 +4,9 @@ "category" : "Seaside-JSON-Core-Brushes", "classinstvars" : [ ], "pools" : [ ], - "classvars" : [ ], + "classvars" : [ + "StringKeysOnly" + ], "instvars" : [ "key" ], diff --git a/repository/Seaside-Pharo70-JSON-Extensions.package/OrderedDictionary.extension/instance/jsonOn..st b/repository/Seaside-Pharo-JSON-Core.package/OrderedDictionary.extension/instance/jsonOn..st similarity index 78% rename from repository/Seaside-Pharo70-JSON-Extensions.package/OrderedDictionary.extension/instance/jsonOn..st rename to repository/Seaside-Pharo-JSON-Core.package/OrderedDictionary.extension/instance/jsonOn..st index f67407d03..dbd08ebf2 100644 --- a/repository/Seaside-Pharo70-JSON-Extensions.package/OrderedDictionary.extension/instance/jsonOn..st +++ b/repository/Seaside-Pharo-JSON-Core.package/OrderedDictionary.extension/instance/jsonOn..st @@ -1,4 +1,4 @@ -*Seaside-Pharo70-JSON-Extensions +*Seaside-Pharo-JSON-Core jsonOn: aRenderer aRenderer object: [ self keysAndValuesDo: [ :key :value | diff --git a/repository/Seaside-Pharo70-JSON-Extensions.package/OrderedDictionary.extension/properties.json b/repository/Seaside-Pharo-JSON-Core.package/OrderedDictionary.extension/properties.json similarity index 100% rename from repository/Seaside-Pharo70-JSON-Extensions.package/OrderedDictionary.extension/properties.json rename to repository/Seaside-Pharo-JSON-Core.package/OrderedDictionary.extension/properties.json diff --git a/repository/Seaside-Pharo-JSON-Core.package/monticello.meta/categories.st b/repository/Seaside-Pharo-JSON-Core.package/monticello.meta/categories.st index 528a5dfee..ea5d7844c 100644 --- a/repository/Seaside-Pharo-JSON-Core.package/monticello.meta/categories.st +++ b/repository/Seaside-Pharo-JSON-Core.package/monticello.meta/categories.st @@ -1 +1,2 @@ SystemOrganization addCategory: #'Seaside-Pharo-JSON-Core'! +SystemOrganization addCategory: #'Seaside-Pharo-JSON-Core-Base'! diff --git a/repository/Seaside-Pharo70-JSON-Extensions.package/.filetree b/repository/Seaside-Pharo70-JSON-Extensions.package/.filetree deleted file mode 100644 index 57a679737..000000000 --- a/repository/Seaside-Pharo70-JSON-Extensions.package/.filetree +++ /dev/null @@ -1,5 +0,0 @@ -{ - "separateMethodMetaAndSource" : false, - "noMethodMetaData" : true, - "useCypressPropertiesFile" : true -} \ No newline at end of file diff --git a/repository/Seaside-Pharo70-JSON-Extensions.package/monticello.meta/categories.st b/repository/Seaside-Pharo70-JSON-Extensions.package/monticello.meta/categories.st deleted file mode 100644 index 2133e83a2..000000000 --- a/repository/Seaside-Pharo70-JSON-Extensions.package/monticello.meta/categories.st +++ /dev/null @@ -1 +0,0 @@ -SystemOrganization addCategory: #'Seaside-Pharo70-JSON-Extensions'! diff --git a/repository/Seaside-Pharo70-JSON-Extensions.package/monticello.meta/initializers.st b/repository/Seaside-Pharo70-JSON-Extensions.package/monticello.meta/initializers.st deleted file mode 100644 index e69de29bb..000000000 diff --git a/repository/Seaside-Pharo70-JSON-Extensions.package/monticello.meta/package b/repository/Seaside-Pharo70-JSON-Extensions.package/monticello.meta/package deleted file mode 100644 index 64875fcc5..000000000 --- a/repository/Seaside-Pharo70-JSON-Extensions.package/monticello.meta/package +++ /dev/null @@ -1 +0,0 @@ -(name 'Seaside-Pharo70-JSON-Extensions') \ No newline at end of file diff --git a/repository/Seaside-Pharo70-JSON-Extensions.package/properties.json b/repository/Seaside-Pharo70-JSON-Extensions.package/properties.json deleted file mode 100644 index 6f31cf5a2..000000000 --- a/repository/Seaside-Pharo70-JSON-Extensions.package/properties.json +++ /dev/null @@ -1 +0,0 @@ -{ } \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testBigArray.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testBigArray.st index 87332696c..1e522075c 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testBigArray.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testBigArray.st @@ -3,6 +3,6 @@ testBigArray | result | result := self parse: ' [ "a" , "b" ] '. self assert: result isArray. - self assert: result size = 2. - self assert: result first = 'a'. - self assert: result second = 'b' \ No newline at end of file + self assert: result size equals: 2. + self assert: result first equals: 'a'. + self assert: result second equals: 'b' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testBigObject.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testBigObject.st index 570b926fc..dd69e7753 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testBigObject.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testBigObject.st @@ -3,6 +3,6 @@ testBigObject | result | result := self parse: ' { "a" : 1 , "b" : 2 } '. self assert: result isDictionary. - self assert: result size = 2. - self assert: (result at: 'a') = 1. - self assert: (result at: 'b') = 2 \ No newline at end of file + self assert: result size equals: 2. + self assert: (result at: 'a') equals: 1. + self assert: (result at: 'b') equals: 2 \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testExplorerEvent.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testExplorerEvent.st index 9e69276fc..c3e54477e 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testExplorerEvent.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testExplorerEvent.st @@ -2,8 +2,8 @@ tests-real testExplorerEvent | result | result := self parse: '{"recordset": null, "type": "change", "fromElement": null, "toElement": null, "altLeft": false, "keyCode": 0, "repeat": false, "reason": 0, "behaviorCookie": 0, "contentOverflow": false, "behaviorPart": 0, "dataTransfer": null, "ctrlKey": false, "shiftLeft": false, "dataFld": "", "qualifier": "", "wheelDelta": 0, "bookmarks": null, "button": 0, "srcFilter": null, "nextPage": "", "cancelBubble": false, "x": 89, "y": 502, "screenX": 231, "screenY": 1694, "srcUrn": "", "boundElements": {"length": 0}, "clientX": 89, "clientY": 502, "propertyName": "", "shiftKey": false, "ctrlLeft": false, "offsetX": 25, "offsetY": 2, "altKey": false}'. - self assert: (result at: 'type') = 'change'. - self assert: (result at: 'offsetY') = 2. + self assert: (result at: 'type') equals: 'change'. + self assert: (result at: 'offsetY') equals: 2. self deny: (result at: 'altKey'). self assert: (result at: 'dataTransfer') isNil. - self assert: (result at: 'nextPage') = '' \ No newline at end of file + self assert: (result at: 'nextPage') equals: '' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testFirefoxEvent.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testFirefoxEvent.st index 62b2add80..cc88d3c53 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testFirefoxEvent.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testFirefoxEvent.st @@ -2,8 +2,8 @@ tests-real testFirefoxEvent | result | result := self parse: '{"type": "change", "eventPhase": 2, "bubbles": true, "cancelable": true, "timeStamp": 0, "CAPTURING_PHASE": 1, "AT_TARGET": 2, "BUBBLING_PHASE": 3, "isTrusted": true, "MOUSEDOWN": 1, "MOUSEUP": 2, "MOUSEOVER": 4, "MOUSEOUT": 8, "MOUSEMOVE": 16, "MOUSEDRAG": 32, "CLICK": 64, "DBLCLICK": 128, "KEYDOWN": 256, "KEYUP": 512, "KEYPRESS": 1024, "DRAGDROP": 2048, "FOCUS": 4096, "BLUR": 8192, "SELECT": 16384, "CHANGE": 32768, "RESET": 65536, "SUBMIT": 131072, "SCROLL": 262144, "LOAD": 524288, "UNLOAD": 1048576, "XFER_DONE": 2097152, "ABORT": 4194304, "ERROR": 8388608, "LOCATE": 16777216, "MOVE": 33554432, "RESIZE": 67108864, "FORWARD": 134217728, "HELP": 268435456, "BACK": 536870912, "TEXT": 1073741824, "ALT_MASK": 1, "CONTROL_MASK": 2, "SHIFT_MASK": 4, "META_MASK": 8}'. - self assert: (result at: 'type') = 'change'. - self assert: (result at: 'eventPhase') = 2. + self assert: (result at: 'type') equals: 'change'. + self assert: (result at: 'eventPhase') equals: 2. self assert: (result at: 'bubbles'). self assert: (result at: 'cancelable'). - self assert: (result at: 'BACK') = 536870912 \ No newline at end of file + self assert: (result at: 'BACK') equals: 536870912 \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testInvalidObject.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testInvalidObject.st index d802a639d..1e4a7d2f8 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testInvalidObject.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testInvalidObject.st @@ -8,4 +8,5 @@ testInvalidObject self assertInvalid: '{"a"}'. self assertInvalid: '{"a":}'. self assertInvalid: '{"a":"b",}'. - self assertInvalid: '{}}' \ No newline at end of file + self assertInvalid: '{}}'. + self assertInvalid: '{1:"a"}' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNestedArray.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNestedArray.st index d1b87ba8e..174c50ba4 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNestedArray.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNestedArray.st @@ -3,8 +3,8 @@ testNestedArray | result | result := self parse: '[[2]]'. self assert: result isArray. - self assert: result size = 1. + self assert: result size equals: 1. result := result first. self assert: result isArray. - self assert: result size = 1. - self assert: result first = 2 \ No newline at end of file + self assert: result size equals: 1. + self assert: result first equals: 2 \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNestedObject.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNestedObject.st index 03f976701..0e5e5b8e7 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNestedObject.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNestedObject.st @@ -3,8 +3,8 @@ testNestedObject | result | result := self parse: '{"object":{"1":"2"}} '. self assert: result isDictionary. - self assert: result size = 1. + self assert: result size equals: 1. result := result at: 'object'. self assert: result isDictionary. - self assert: result size = 1. - self assert: (result at: '1') = '2' \ No newline at end of file + self assert: result size equals: 1. + self assert: (result at: '1') equals: '2' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNonBmpCodePoints.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNonBmpCodePoints.st index fd83182ac..03decfd7d 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNonBmpCodePoints.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNonBmpCodePoints.st @@ -7,6 +7,6 @@ testNonBmpCodePoints "dutch flag as two surrogate pairs" parsed := self parse: '"\uD83C\uDDF3\uD83C\uDDF1"'. - self assert: parsed size = 2. - self assert: parsed first codePoint = 16r1F1F3. "Regional Indicator Symbol Letter N" - self assert: parsed second codePoint = 16r1F1F1 "Regional Indicator Symbol Letter L" \ No newline at end of file + self assert: parsed size equals: 2. + self assert: parsed first codePoint equals: 16r1F1F3. "Regional Indicator Symbol Letter N" + self assert: parsed second codePoint equals: 16r1F1F1 "Regional Indicator Symbol Letter L" \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNumberFloat.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNumberFloat.st index f56647694..7d3f058c8 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNumberFloat.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNumberFloat.st @@ -1,10 +1,10 @@ tests-literals testNumberFloat - self assert: (self parse: '0.0') = 0.0. - self assert: (self parse: '0.12') = 0.12. - self assert: (self parse: '-0.12') = -0.12. - self assert: (self parse: '12.34') = 12.34. - self assert: (self parse: '-12.34') = -12.34. - self assert: (self parse: '1.2e0') = 1.2. - self assert: (self parse: '1.2e+1') = 12.0. - self assert: (self parse: '1.2e-1') = 1.2e-1 \ No newline at end of file + self assert: (self parse: '0.0') equals: 0.0. + self assert: (self parse: '0.12') equals: 0.12. + self assert: (self parse: '-0.12') equals: -0.12. + self assert: (self parse: '12.34') equals: 12.34. + self assert: (self parse: '-12.34') equals: -12.34. + self assert: (self parse: '1.2e0') equals: 1.2. + self assert: (self parse: '1.2e+1') equals: 12.0. + self assert: (self parse: '1.2e-1') equals: 1.2e-1 \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNumberInteger.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNumberInteger.st index 707707580..44782e3e8 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNumberInteger.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testNumberInteger.st @@ -1,9 +1,9 @@ tests-literals testNumberInteger - self assert: (self parse: '0') = 0. - self assert: (self parse: '1') = 1. - self assert: (self parse: '-1') = -1. - self assert: (self parse: '12') = 12. - self assert: (self parse: '-12') = -12. - self assert: (self parse: '1e2') = 100. - self assert: (self parse: '1e+2') = 100 \ No newline at end of file + self assert: (self parse: '0') equals: 0. + self assert: (self parse: '1') equals: 1. + self assert: (self parse: '-1') equals: -1. + self assert: (self parse: '12') equals: 12. + self assert: (self parse: '-12') equals: -12. + self assert: (self parse: '1e2') equals: 100. + self assert: (self parse: '1e+2') equals: 100 \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testSafariEvent.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testSafariEvent.st index 8b605326f..c3f22632e 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testSafariEvent.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testSafariEvent.st @@ -2,9 +2,9 @@ tests-real testSafariEvent | result | result := self parse: '{"returnValue": true, "timeStamp": 1226697417289, "eventPhase": 2, "type": "change", "cancelable": false, "bubbles": true, "cancelBubble": false, "MOUSEOUT": 8, "FOCUS": 4096, "CHANGE": 32768, "MOUSEMOVE": 16, "AT_TARGET": 2, "SELECT": 16384, "BLUR": 8192, "KEYUP": 512, "MOUSEDOWN": 1, "MOUSEDRAG": 32, "BUBBLING_PHASE": 3, "MOUSEUP": 2, "CAPTURING_PHASE": 1, "MOUSEOVER": 4, "CLICK": 64, "DBLCLICK": 128, "KEYDOWN": 256, "KEYPRESS": 1024, "DRAGDROP": 2048}'. - self assert: (result at: 'type') = 'change'. - self assert: (result at: 'eventPhase') = 2. + self assert: (result at: 'type') equals: 'change'. + self assert: (result at: 'eventPhase') equals: 2. self assert: (result at: 'bubbles'). self deny: (result at: 'cancelBubble'). self deny: (result at: 'cancelable'). - self assert: (result at: 'BLUR') = 8192 \ No newline at end of file + self assert: (result at: 'BLUR') equals: 8192 \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testSmallArray.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testSmallArray.st index 1516d6dcd..826189a08 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testSmallArray.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testSmallArray.st @@ -3,5 +3,5 @@ testSmallArray | result | result := self parse: '["a"]'. self assert: result isArray. - self assert: result size = 1. - self assert: result first = 'a' \ No newline at end of file + self assert: result size equals: 1. + self assert: result first equals: 'a' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testSmallObject.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testSmallObject.st index 01210c1ff..c62ca76d9 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testSmallObject.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testSmallObject.st @@ -3,5 +3,5 @@ testSmallObject | result | result := self parse: '{"a":1}'. self assert: result isDictionary. - self assert: result size = 1. - self assert: (result at: 'a') = 1 \ No newline at end of file + self assert: result size equals: 1. + self assert: (result at: 'a') equals: 1 \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testString.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testString.st index e30a96538..470d1fde8 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testString.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testString.st @@ -1,6 +1,6 @@ tests-literals testString - self assert: (self parse: '""') = ''. - self assert: (self parse: '"foo"') = 'foo'. - self assert: (self parse: '"foo bar"') = 'foo bar'. - self assert: (self parse: '" foo "') = ' foo ' \ No newline at end of file + self assert: (self parse: '""') equals: ''. + self assert: (self parse: '"foo"') equals: 'foo'. + self assert: (self parse: '"foo bar"') equals: 'foo bar'. + self assert: (self parse: '" foo "') equals: ' foo ' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testStringEscaped.st b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testStringEscaped.st index b80a0d46b..edba51bec 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testStringEscaped.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonParserTest.class/instance/testStringEscaped.st @@ -1,11 +1,11 @@ tests-literals testStringEscaped - self assert: (self parse: '"\""') = '"'. - self assert: (self parse: '"\\"') = '\'. - self assert: (self parse: '"\/"') = '/'. - self assert: (self parse: '"\b"') = (String with: Character backspace). - self assert: (self parse: '"\f"') = (String with: Character newPage). - self assert: (self parse: '"\n"') = (String with: Character lf). - self assert: (self parse: '"\r"') = (String with: Character cr). - self assert: (self parse: '"\t"') = (String with: Character tab). - self assert: (self parse: '"\u20Ac"') = (String with: (Character codePoint: 16r20AC)) \ No newline at end of file + self assert: (self parse: '"\""') equals: '"'. + self assert: (self parse: '"\\"') equals: '\'. + self assert: (self parse: '"\/"') equals: '/'. + self assert: (self parse: '"\b"') equals: (String with: Character backspace). + self assert: (self parse: '"\f"') equals: (String with: Character newPage). + self assert: (self parse: '"\n"') equals: (String with: Character lf). + self assert: (self parse: '"\r"') equals: (String with: Character cr). + self assert: (self parse: '"\t"') equals: (String with: Character tab). + self assert: (self parse: '"\u20Ac"') equals: (String with: (Character codePoint: 16r20AC)) \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonRenderingTest.class/instance/testObject.st b/repository/Seaside-Tests-JSON.package/WAJsonRenderingTest.class/instance/testObject.st index b016d1811..47ecb0595 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonRenderingTest.class/instance/testObject.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonRenderingTest.class/instance/testObject.st @@ -11,4 +11,17 @@ testObject assert: [ :json | json object: [ json key: '1' value: 1 ] ] - gives: '{"1": 1}' \ No newline at end of file + gives: '{"1": 1}'. + + WAJsonKeyValueBrush stringKeysOnly: true. + self + should: [ + self + assert: [ :json | + json object: [ + json key: 1 value: 1 ] ] + gives: '{"1": 1}' ] + raise: Error + withExceptionDo: [ :e | self assert: e messageText equals: 'Only Strings can be used as keys in JSON objects.' ]. + + \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/assert.equals..st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/assert.gives..st similarity index 81% rename from repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/assert.equals..st rename to repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/assert.gives..st index 4924fbe3a..381bdc89c 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/assert.equals..st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/assert.gives..st @@ -1,5 +1,5 @@ asserting -assert: anObject equals: aString +assert: anObject gives: aString self assert: anObject asJson = aString description: anObject asJson , ' expected to be ' , aString greaseString diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/assert.equalsIgnoreCase..st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/assert.givesIgnoreCase..st similarity index 79% rename from repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/assert.equalsIgnoreCase..st rename to repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/assert.givesIgnoreCase..st index 57f4e157e..4bb1b5777 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/assert.equalsIgnoreCase..st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/assert.givesIgnoreCase..st @@ -1,5 +1,5 @@ asserting -assert: anObject equalsIgnoreCase: aString +assert: anObject givesIgnoreCase: aString self assert: anObject asJson asLowercase = aString asLowercase description: anObject asJson , ' expected to be ' , aString greaseString diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testArray.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testArray.st index c7db25e46..7935f8d1e 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testArray.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testArray.st @@ -1,3 +1,3 @@ tests testArray - self assert: #(1 2 3) equals: '[1, 2, 3]' \ No newline at end of file + self assert: #(1 2 3) gives: '[1, 2, 3]' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCharacter.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCharacter.st index 4534ebeae..3242860de 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCharacter.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCharacter.st @@ -1,3 +1,3 @@ tests-literals testCharacter - self assert: $a equals: '"a"' \ No newline at end of file + self assert: $a gives: '"a"' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCustomArray.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCustomArray.st index fde4b14aa..421ac5008 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCustomArray.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCustomArray.st @@ -1,4 +1,4 @@ tests-custom testCustomArray printer := [ :renderer | renderer render: #('aString1' ('aString2' 'aString3')) ]. - self assert: self equals: '["aString1", ["aString2", "aString3"]]' \ No newline at end of file + self assert: self gives: '["aString1", ["aString2", "aString3"]]' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCustomCollection.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCustomCollection.st index d543195b9..4a412bb17 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCustomCollection.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCustomCollection.st @@ -1,4 +1,4 @@ tests-custom testCustomCollection printer := [ :renderer | renderer render: (GRSmallOrderedSet withAll: #('aString2' 'aString3')) ]. - self assert: self equals: '["aString2", "aString3"]' \ No newline at end of file + self assert: self gives: '["aString2", "aString3"]' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCustomDictionary.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCustomDictionary.st index 010c1e3c5..fcb7b9388 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCustomDictionary.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testCustomDictionary.st @@ -7,4 +7,4 @@ testCustomDictionary at: 'foo' put: 'bar'; yourself); yourself) ]. - self assert: self equals: '{"foo": "bar", "zork": {"foo": "bar"}}' \ No newline at end of file + self assert: self gives: '{"foo": "bar", "zork": {"foo": "bar"}}' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testDictionary.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testDictionary.st index e0d164afd..7da7b7742 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testDictionary.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testDictionary.st @@ -7,28 +7,23 @@ testDictionary at: 'bar' put: 2; at: 'zork' put: 3; yourself) - equals: '{"foo": 1, "bar": 2, "zork": 3}'. + gives: '{"foo": 1, "bar": 2, "zork": 3}'. self assert: ((GRSmallDictionary2 new) at: '' put: 'empty'; yourself) - equals: '{"": "empty"}'. - self - assert: - ((Dictionary new) - at: 1 put: 'not-a-string'; - yourself) - equals: '{1: "not-a-string"}'. + gives: '{"": "empty"}'. + self assert: ((Dictionary new) at: '1abc' put: 'not-an-id'; yourself) - equals: '{"1abc": "not-an-id"}'. + gives: '{"1abc": "not-an-id"}'. self assert: ((Dictionary new) at: 'abc1' put: 'totally sexy'; yourself) - equals: '{"abc1": "totally sexy"}' \ No newline at end of file + gives: '{"abc1": "totally sexy"}' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testDictionaryWithNonStringKeys.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testDictionaryWithNonStringKeys.st new file mode 100644 index 000000000..7d5cf25ef --- /dev/null +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testDictionaryWithNonStringKeys.st @@ -0,0 +1,20 @@ +tests +testDictionaryWithNonStringKeys + + WAJsonKeyValueBrush stringKeysOnly: true. + + self + should: [ + (Dictionary new + at: #( 1 2 ) put: 'awkward'; + yourself) asJson ] + raise: Error + withExceptionDo: [ :e | self assert: e messageText equals: 'Only Strings can be used as keys in JSON objects.' ]. + + self + should: [ + ((Dictionary new) + at: 1 put: 'not-a-string'; + yourself) asJson ] + raise: Error + withExceptionDo: [ :e | self assert: e messageText equals: 'Only Strings can be used as keys in JSON objects.' ]. \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testLiteral.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testLiteral.st index 7d5ece62c..3bb5f912a 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testLiteral.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testLiteral.st @@ -1,5 +1,5 @@ tests-literals testLiteral - self assert: true equals: 'true'. - self assert: false equals: 'false'. - self assert: nil equals: 'null' \ No newline at end of file + self assert: true gives: 'true'. + self assert: false gives: 'false'. + self assert: nil gives: 'null' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testNumber.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testNumber.st index fb7c84e49..678f5ecfd 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testNumber.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testNumber.st @@ -1,4 +1,4 @@ tests-literals testNumber - self assert: 123 equals: '123'. - self assert: 123.4 equals: '123.4' \ No newline at end of file + self assert: 123 gives: '123'. + self assert: 123.4 gives: '123.4' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringBasic.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringBasic.st index 04fc9af88..947289d5e 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringBasic.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringBasic.st @@ -1,4 +1,4 @@ tests-literals testStringBasic - self assert: 'abc' equals: '"abc"'. - self assert: '123' equals: '"123"' \ No newline at end of file + self assert: 'abc' gives: '"abc"'. + self assert: '123' gives: '"123"' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringEscaping.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringEscaping.st index a7aa55d50..0b91b4bd6 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringEscaping.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringEscaping.st @@ -1,5 +1,5 @@ tests-literals testStringEscaping - self assert: '''' equals: '"''"'. - self assert: '"' equals: '"\""'. - self assert: '\' equals: '"\\"' \ No newline at end of file + self assert: '''' gives: '"''"'. + self assert: '"' gives: '"\""'. + self assert: '\' gives: '"\\"' \ No newline at end of file diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringMultiByte.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringMultiByte.st index 6a8be2d45..cc28ae74c 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringMultiByte.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringMultiByte.st @@ -5,4 +5,4 @@ testStringMultiByte http://code.google.com/p/glassdb/issues/detail?id=217" | multibyteString | multibyteString := String with: (Character codePoint: 8364). - self assert: multibyteString equals: '"', multibyteString, '"' + self assert: multibyteString gives: '"', multibyteString, '"' diff --git a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringSpecial.st b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringSpecial.st index d9aea93f5..9a94e82ef 100644 --- a/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringSpecial.st +++ b/repository/Seaside-Tests-JSON.package/WAJsonStreamTest.class/instance/testStringSpecial.st @@ -1,10 +1,10 @@ tests-literals testStringSpecial - self assert: (String with: Character cr) equals: '"\r"'. - self assert: (String with: Character lf) equals: '"\n"'. - self assert: (String with: Character tab) equals: '"\t"'. - self assert: (String with: (Character codePoint: 8)) equals: '"\b"'. - self assert: (String with: (Character codePoint: 12)) equals: '"\f"'. + self assert: (String with: Character cr) gives: '"\r"'. + self assert: (String with: Character lf) gives: '"\n"'. + self assert: (String with: Character tab) gives: '"\t"'. + self assert: (String with: (Character codePoint: 8)) gives: '"\b"'. + self assert: (String with: (Character codePoint: 12)) gives: '"\f"'. "http://tools.ietf.org/html/rfc4627#section-2.5" 0 to: 16r001F do: [ :codePoint | @@ -12,4 +12,4 @@ testStringSpecial self assert: (String with: (Character codePoint: codePoint)) "case doesn't matter" - equalsIgnoreCase: '"\u', ((codePoint printStringBase: 16) padLeftTo: 4 with: $0), '"' ] ] \ No newline at end of file + givesIgnoreCase: '"\u', ((codePoint printStringBase: 16) padLeftTo: 4 with: $0), '"' ] ] \ No newline at end of file diff --git a/repository/Seaside-Tests-Pharo-JSON-Core.package/.filetree b/repository/Seaside-Tests-Pharo-JSON-Core.package/.filetree index 8998102c2..57a679737 100644 --- a/repository/Seaside-Tests-Pharo-JSON-Core.package/.filetree +++ b/repository/Seaside-Tests-Pharo-JSON-Core.package/.filetree @@ -1,4 +1,5 @@ { - "noMethodMetaData" : true, "separateMethodMetaAndSource" : false, - "useCypressPropertiesFile" : true } + "noMethodMetaData" : true, + "useCypressPropertiesFile" : true +} \ No newline at end of file diff --git a/repository/Seaside-Tests-Pharo-JSON-Core.package/WAJsonStreamTest.extension/instance/testOrderedDictionary.st b/repository/Seaside-Tests-Pharo-JSON-Core.package/WAJsonStreamTest.extension/instance/testOrderedDictionary.st new file mode 100644 index 000000000..9ef10afc9 --- /dev/null +++ b/repository/Seaside-Tests-Pharo-JSON-Core.package/WAJsonStreamTest.extension/instance/testOrderedDictionary.st @@ -0,0 +1,38 @@ +*Seaside-Tests-Pharo-JSON-Core +testOrderedDictionary + self + assert: + ((OrderedDictionary new) + at: 'foo' put: 1; + at: 'bar' put: 2; + at: 'zork' put: 3; + yourself) + gives: '{"foo": 1, "bar": 2, "zork": 3}'. + self + assert: + ((OrderedDictionary new) + at: '' put: 'empty'; + yourself) + gives: '{"": "empty"}'. + self should: [ + self + assert: + ((OrderedDictionary new) + at: 1 put: 'not-a-string'; + yourself) + gives: '{1: "not-a-string"}' ] + raise: Error + withExceptionDo: [ :e | self assert: e messageText equals: 'Only Strings can be used as keys in JSON objects.' ]. + self + assert: + ((OrderedDictionary new) + at: '1abc' put: 'not-an-id'; + yourself) + gives: '{"1abc": "not-an-id"}'. + + self + assert: + ((OrderedDictionary new) + at: 'abc1' put: 'totally sexy'; + yourself) + gives: '{"abc1": "totally sexy"}' \ No newline at end of file diff --git a/repository/Seaside-Tests-Pharo-JSON-Core.package/WAJsonStreamTest.extension/instance/testScaledDecimal.st b/repository/Seaside-Tests-Pharo-JSON-Core.package/WAJsonStreamTest.extension/instance/testScaledDecimal.st index accac4b59..bfec73335 100644 --- a/repository/Seaside-Tests-Pharo-JSON-Core.package/WAJsonStreamTest.extension/instance/testScaledDecimal.st +++ b/repository/Seaside-Tests-Pharo-JSON-Core.package/WAJsonStreamTest.extension/instance/testScaledDecimal.st @@ -1,3 +1,3 @@ *seaside-tests-pharo-json-core testScaledDecimal - self assert: 123.4s1 equals: '123.4' \ No newline at end of file + self assert: 123.4s1 gives: '123.4' \ No newline at end of file diff --git a/repository/Seaside-Tests-Pharo-JSON-Core.package/WAJsonStreamTest.extension/properties.json b/repository/Seaside-Tests-Pharo-JSON-Core.package/WAJsonStreamTest.extension/properties.json index cc974caf8..8e29b2deb 100644 --- a/repository/Seaside-Tests-Pharo-JSON-Core.package/WAJsonStreamTest.extension/properties.json +++ b/repository/Seaside-Tests-Pharo-JSON-Core.package/WAJsonStreamTest.extension/properties.json @@ -1,2 +1,3 @@ { - "name" : "WAJsonStreamTest" } + "name" : "WAJsonStreamTest" +} \ No newline at end of file diff --git a/repository/Seaside-Tests-Pharo-JSON-Core.package/monticello.meta/categories.st b/repository/Seaside-Tests-Pharo-JSON-Core.package/monticello.meta/categories.st new file mode 100644 index 000000000..3c3132e36 --- /dev/null +++ b/repository/Seaside-Tests-Pharo-JSON-Core.package/monticello.meta/categories.st @@ -0,0 +1 @@ +SystemOrganization addCategory: #'Seaside-Tests-Pharo-JSON-Core'! diff --git a/repository/Seaside-Tests-Pharo-JSON-Core.package/monticello.meta/version b/repository/Seaside-Tests-Pharo-JSON-Core.package/monticello.meta/version deleted file mode 100644 index 96d6793b7..000000000 --- a/repository/Seaside-Tests-Pharo-JSON-Core.package/monticello.meta/version +++ /dev/null @@ -1 +0,0 @@ -(name 'Seaside-Tests-Pharo-JSON-Core-pmm.1' message 'Issue 770: ScaledDecimal rendering support http://code.google.com/p/seaside/issues/detail?id=770' id '177c1aa1-85e9-4994-9086-0e98bf6454cf' date '15 September 2013' time '12:13:34 pm' author 'pmm' ancestors () stepChildren ()) \ No newline at end of file diff --git a/repository/Seaside-Tests-Pharo-JSON-Core.package/properties.json b/repository/Seaside-Tests-Pharo-JSON-Core.package/properties.json index f037444a7..6f31cf5a2 100644 --- a/repository/Seaside-Tests-Pharo-JSON-Core.package/properties.json +++ b/repository/Seaside-Tests-Pharo-JSON-Core.package/properties.json @@ -1,2 +1 @@ -{ - } +{ } \ No newline at end of file diff --git a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/.filetree b/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/.filetree deleted file mode 100644 index 57a679737..000000000 --- a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/.filetree +++ /dev/null @@ -1,5 +0,0 @@ -{ - "separateMethodMetaAndSource" : false, - "noMethodMetaData" : true, - "useCypressPropertiesFile" : true -} \ No newline at end of file diff --git a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/WAJsonStreamTest.extension/instance/testOrderedDictionary.st b/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/WAJsonStreamTest.extension/instance/testOrderedDictionary.st deleted file mode 100644 index 504c723d7..000000000 --- a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/WAJsonStreamTest.extension/instance/testOrderedDictionary.st +++ /dev/null @@ -1,34 +0,0 @@ -*Seaside-Tests-Pharo70-JSON-Extensions -testOrderedDictionary - self - assert: - ((OrderedDictionary new) - at: 'foo' put: 1; - at: 'bar' put: 2; - at: 'zork' put: 3; - yourself) - equals: '{"foo": 1, "bar": 2, "zork": 3}'. - self - assert: - ((OrderedDictionary new) - at: '' put: 'empty'; - yourself) - equals: '{"": "empty"}'. - self - assert: - ((OrderedDictionary new) - at: 1 put: 'not-a-string'; - yourself) - equals: '{1: "not-a-string"}'. - self - assert: - ((OrderedDictionary new) - at: '1abc' put: 'not-an-id'; - yourself) - equals: '{"1abc": "not-an-id"}'. - self - assert: - ((OrderedDictionary new) - at: 'abc1' put: 'totally sexy'; - yourself) - equals: '{"abc1": "totally sexy"}' \ No newline at end of file diff --git a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/WAJsonStreamTest.extension/properties.json b/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/WAJsonStreamTest.extension/properties.json deleted file mode 100644 index 8e29b2deb..000000000 --- a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/WAJsonStreamTest.extension/properties.json +++ /dev/null @@ -1,3 +0,0 @@ -{ - "name" : "WAJsonStreamTest" -} \ No newline at end of file diff --git a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/monticello.meta/categories.st b/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/monticello.meta/categories.st deleted file mode 100644 index 56d385391..000000000 --- a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/monticello.meta/categories.st +++ /dev/null @@ -1 +0,0 @@ -SystemOrganization addCategory: #'Seaside-Tests-Pharo70-JSON-Extensions'! diff --git a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/monticello.meta/initializers.st b/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/monticello.meta/initializers.st deleted file mode 100644 index e69de29bb..000000000 diff --git a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/monticello.meta/package b/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/monticello.meta/package deleted file mode 100644 index 646dbada7..000000000 --- a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/monticello.meta/package +++ /dev/null @@ -1 +0,0 @@ -(name 'Seaside-Tests-Pharo70-JSON-Extensions') \ No newline at end of file diff --git a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/properties.json b/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/properties.json deleted file mode 100644 index 6f31cf5a2..000000000 --- a/repository/Seaside-Tests-Pharo70-JSON-Extensions.package/properties.json +++ /dev/null @@ -1 +0,0 @@ -{ } \ No newline at end of file