@@ -20,10 +20,21 @@ def test_semicolon_separated_args(self):
2020 result = fix_modulesArgs (['/mod.so' ], 'KEY1 V1; KEY2 V2' )
2121 self .assertEqual (result , [['KEY1 V1' , 'KEY2 V2' ]])
2222
23- # 4a. Odd number of words without semicolons - should error
24- def test_odd_words_no_semicolons_exits (self ):
25- with self .assertRaises (SystemExit ):
26- fix_modulesArgs (['/mod.so' ], 'FLAG TIMEOUT 80' )
23+ # 4a. Odd number of words without semicolons - should NOT crash (kept as single entry)
24+ def test_odd_words_no_semicolons_no_crash (self ):
25+ # 3 words (odd) - kept as a single unsplit arg string
26+ result = fix_modulesArgs (['/mod.so' ], 'FLAG TIMEOUT 80' )
27+ self .assertEqual (result , [['FLAG TIMEOUT 80' ]])
28+
29+ # 4a2. Odd number of words (5 words) without semicolons - should NOT crash
30+ def test_odd_words_five_words_no_crash (self ):
31+ result = fix_modulesArgs (['/mod.so' ], 'KEY1 VAL1 KEY2 VAL2 FLAG' )
32+ self .assertEqual (result , [['KEY1 VAL1 KEY2 VAL2 FLAG' ]])
33+
34+ # 4a3. Single word without semicolons - should NOT crash
35+ def test_single_word_no_crash (self ):
36+ result = fix_modulesArgs (['/mod.so' ], 'FLAG' )
37+ self .assertEqual (result , [['FLAG' ]])
2738
2839 # 4b. Odd number of words with semicolons - valid, semicolons split first
2940 def test_odd_words_with_semicolons_valid (self ):
0 commit comments