Skip to content

Commit 1eea408

Browse files
committed
Empty tag values and no values are now the same, tests now reflect this
1 parent 55b14f4 commit 1eea408

File tree

2 files changed

+10
-12
lines changed

2 files changed

+10
-12
lines changed

tests/msg-join.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,7 @@ tests:
2323

2424
# the atoms dict has the keys:
2525
# * tags: tags dict
26-
# tags with no equals sign have a value of null in this file
27-
# tags with no value after = sign have a value of empty string
26+
# tags with no value are an empty string
2827
# * source: source string, without single leading colon
2928
# * verb: verb string
3029
# * params: params split up as a list
@@ -178,7 +177,7 @@ tests:
178177
- desc: Tag with no value and space-filled trailing.
179178
atoms:
180179
tags:
181-
"asd": null
180+
"asd": ""
182181
source: "coolguy"
183182
verb: "foo"
184183
params:

tests/msg-split.yaml

Lines changed: 8 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,7 @@ tests:
2828

2929
# the atoms dict has the keys:
3030
# * tags: tags dict
31-
# tags with no equals sign have a value of null in this file
32-
# tags with no value after = sign have a value of empty string
31+
# tags with no value are an empty string
3332
# * source: source string, without single leading colon
3433
# * verb: verb string
3534
# * params: params split up as a list
@@ -134,7 +133,7 @@ tests:
134133
tags:
135134
"a": "b"
136135
"c": "32"
137-
"k": null
136+
"k": ""
138137
"rt": "ql7"
139138

140139
# with escaped tags
@@ -150,7 +149,7 @@ tests:
150149
- input: "@c;h=;a=b :quux ab cd"
151150
atoms:
152151
tags:
153-
"c": null
152+
"c": ""
154153
"h": ""
155154
"a": "b"
156155
source: "quux"
@@ -210,13 +209,13 @@ tests:
210209
- "foo"
211210
- "bar baz"
212211

213-
- input: "@tag1=value1;tag2;vendor1/tag3=value2;vendor2/tag4 :irc.example.com COMMAND param1 param2 :param3 param3"
212+
- input: "@tag1=value1;tag2;vendor1/tag3=value2;vendor2/tag4= :irc.example.com COMMAND param1 param2 :param3 param3"
214213
atoms:
215214
tags:
216215
tag1: "value1"
217-
tag2: null
216+
tag2: ""
218217
vendor1/tag3: "value2"
219-
vendor2/tag4: null
218+
vendor2/tag4: ""
220219
source: "irc.example.com"
221220
verb: "COMMAND"
222221
params:
@@ -237,9 +236,9 @@ tests:
237236
atoms:
238237
tags:
239238
tag1: "value1"
240-
tag2: null
239+
tag2: ""
241240
vendor1/tag3: "value2"
242-
vendor2/tag4: null
241+
vendor2/tag4: ""
243242
verb: "COMMAND"
244243
params:
245244
- "param1"

0 commit comments

Comments
 (0)