forked from ObjectProfile/PythonBridge
-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathPBSerializeTest.class.st
More file actions
46 lines (40 loc) · 1 KB
/
PBSerializeTest.class.st
File metadata and controls
46 lines (40 loc) · 1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
Class {
#name : #PBSerializeTest,
#superclass : #TestCase,
#instVars : [
'mapper'
],
#category : #'PythonBridge-Tests'
}
{ #category : #accessing }
PBSerializeTest >> application [
^ PBApplication uniqueInstance
]
{ #category : #tests }
PBSerializeTest >> serializer [
^ mapper serializer
serializerWrapper: PBPlatform current class httpMessageBrokerClass serializer;
yourself
]
{ #category : #tests }
PBSerializeTest >> setUp [
| execHandler app |
super setUp.
app := PBStubApplication new.
execHandler := PBExecutionHandler basicNew
application: app;
yourself.
mapper := LanguageLinkMapperFactory forExecutionHandler: execHandler
]
{ #category : #accessing }
PBSerializeTest >> settings [
^ PBPlatform current defaultSettings
]
{ #category : #tests }
PBSerializeTest >> testSerializeArray [
self assert: (self serializer serialize: #(33 'foo')) equals: '[33,"foo"]'
]
{ #category : #tests }
PBSerializeTest >> testSerializeNil [
self assert: (self serializer serialize: nil) equals: 'null'
]