smalltalk
/
osmo-st-smpp
Archived
1
0
Fork 0

bind: Add getters and extend the testcase of reading the message

This commit is contained in:
Holger Hans Peter Freyther 2014-05-12 10:02:36 +02:00
parent 5ec92351f5
commit 07319cd1aa
2 changed files with 36 additions and 0 deletions

View File

@ -34,4 +34,32 @@ SMPPBodyBase subclass: SMPPBindTransmitterBody [
add: SMPPAddressRange tlvDescription;
yourself
]
systemdId [
^systemd_id
]
password [
^password
]
systemType [
^system_type
]
version [
^0
]
typeOfNumber [
^addr_ton
]
numberingPlanIndicator [
^addr_npi
]
addressRange [
^addr_range
]
]

View File

@ -35,6 +35,14 @@ TestCase subclass: SMPPMessageTest [
self assert: msg header commandId equals: 2.
self assert: msg header commandStatus equals: 0.
self assert: msg header sequenceNumber equals: 1.
self assert: msg body systemdId equals: 'SMPP3TEST'.
self assert: msg body password equals: 'secret08'.
self assert: msg body systemType equals: 'SUBMIT1'.
self assert: msg body version equals: 0.
self assert: msg body typeOfNumber equals: 1.
self assert: msg body numberingPlanIndicator equals: 1.
self assert: msg body addressRange equals: ''.
]
testWriteMessage [