@@ -96,126 +96,147 @@ run_validate "$F" > /dev/null 2>&1 || EXIT_CODE=$?
9696[[ $EXIT_CODE -ne 0 ]] && pass " duplicate direction_id: exits non-zero" \
9797 || fail " duplicate direction_id: exits non-zero" " non-zero" " $EXIT_CODE "
9898
99- # NT-6: Duplicate dir_slug
99+ # NT-6: Empty direction_id
100+ F=$( make_fixture " empty-direction-id" ' .directions[0].direction_id = ""' )
101+ EXIT_CODE=0
102+ run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
103+ [[ $EXIT_CODE -ne 0 ]] && pass " empty direction_id: exits non-zero" \
104+ || fail " empty direction_id: exits non-zero" " non-zero" " $EXIT_CODE "
105+
106+ # NT-7: Whitespace-only direction_id
107+ F=$( make_fixture " whitespace-direction-id" ' .directions[0].direction_id = " "' )
108+ EXIT_CODE=0
109+ run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
110+ [[ $EXIT_CODE -ne 0 ]] && pass " whitespace-only direction_id: exits non-zero" \
111+ || fail " whitespace-only direction_id: exits non-zero" " non-zero" " $EXIT_CODE "
112+
113+ # NT-8: direction_id contains spaces
114+ F=$( make_fixture " spaced-direction-id" ' .directions[0].direction_id = "dir 00 command history"' )
115+ EXIT_CODE=0
116+ run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
117+ [[ $EXIT_CODE -ne 0 ]] && pass " direction_id with spaces: exits non-zero" \
118+ || fail " direction_id with spaces: exits non-zero" " non-zero" " $EXIT_CODE "
119+
120+ # NT-9: Duplicate dir_slug
100121F=$( make_fixture " dup-dir-slug" ' .directions[1].dir_slug = .directions[0].dir_slug' )
101122EXIT_CODE=0
102123run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
103124[[ $EXIT_CODE -ne 0 ]] && pass " duplicate dir_slug: exits non-zero" \
104125 || fail " duplicate dir_slug: exits non-zero" " non-zero" " $EXIT_CODE "
105126
106- # NT-7 : Duplicate source_index
127+ # NT-10 : Duplicate source_index
107128F=$( make_fixture " dup-source-index" ' .directions[1].source_index = .directions[0].source_index' )
108129EXIT_CODE=0
109130run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
110131[[ $EXIT_CODE -ne 0 ]] && pass " duplicate source_index: exits non-zero" \
111132 || fail " duplicate source_index: exits non-zero" " non-zero" " $EXIT_CODE "
112133
113- # NT-8 : display_order is a string (not integer)
134+ # NT-11 : display_order is a string (not integer)
114135F=$( make_fixture " display-order-string" ' .directions[0].display_order = "zero"' )
115136EXIT_CODE=0
116137run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
117138[[ $EXIT_CODE -ne 0 ]] && pass " display_order string: exits non-zero" \
118139 || fail " display_order string: exits non-zero" " non-zero" " $EXIT_CODE "
119140
120- # NT-9 : dir_slug contains uppercase
141+ # NT-12 : dir_slug contains uppercase
121142F=$( make_fixture " dir-slug-uppercase" ' .directions[0].dir_slug = "CommandHistory"' )
122143EXIT_CODE=0
123144run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
124145[[ $EXIT_CODE -ne 0 ]] && pass " dir_slug uppercase: exits non-zero" \
125146 || fail " dir_slug uppercase: exits non-zero" " non-zero" " $EXIT_CODE "
126147
127- # NT-10 : dir_slug contains spaces
148+ # NT-13 : dir_slug contains spaces
128149F=$( make_fixture " dir-slug-space" ' .directions[0].dir_slug = "command history"' )
129150EXIT_CODE=0
130151run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
131152[[ $EXIT_CODE -ne 0 ]] && pass " dir_slug with spaces: exits non-zero" \
132153 || fail " dir_slug with spaces: exits non-zero" " non-zero" " $EXIT_CODE "
133154
134- # NT-11 : Missing required per-direction field (name)
155+ # NT-14 : Missing required per-direction field (name)
135156F=$( make_fixture " missing-name" ' .directions[0] |= del(.name)' )
136157EXIT_CODE=0
137158run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
138159[[ $EXIT_CODE -ne 0 ]] && pass " missing direction.name: exits non-zero" \
139160 || fail " missing direction.name: exits non-zero" " non-zero" " $EXIT_CODE "
140161
141- # NT-12 : objective_evidence is not an array
162+ # NT-15 : objective_evidence is not an array
142163F=$( make_fixture " evidence-not-array" ' .directions[0].objective_evidence = "single string"' )
143164EXIT_CODE=0
144165run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
145166[[ $EXIT_CODE -ne 0 ]] && pass " objective_evidence not array: exits non-zero" \
146167 || fail " objective_evidence not array: exits non-zero" " non-zero" " $EXIT_CODE "
147168
148- # NT-13 : known_risks is not an array
169+ # NT-16 : known_risks is not an array
149170F=$( make_fixture " risks-not-array" ' .directions[0].known_risks = "single string"' )
150171EXIT_CODE=0
151172run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
152173[[ $EXIT_CODE -ne 0 ]] && pass " known_risks not array: exits non-zero" \
153174 || fail " known_risks not array: exits non-zero" " non-zero" " $EXIT_CODE "
154175
155- # NT-14 : Invalid confidence value
176+ # NT-17 : Invalid confidence value
156177F=$( make_fixture " bad-confidence" ' .directions[0].confidence = "maybe"' )
157178EXIT_CODE=0
158179run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
159180[[ $EXIT_CODE -ne 0 ]] && pass " invalid confidence: exits non-zero" \
160181 || fail " invalid confidence: exits non-zero" " non-zero" " $EXIT_CODE "
161182
162- # NT-15 : metadata.n_returned mismatch
183+ # NT-18 : metadata.n_returned mismatch
163184F=$( make_fixture " n-returned-mismatch" ' .metadata.n_returned = 99' )
164185EXIT_CODE=0
165186run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
166187[[ $EXIT_CODE -ne 0 ]] && pass " n_returned mismatch: exits non-zero" \
167188 || fail " n_returned mismatch: exits non-zero" " non-zero" " $EXIT_CODE "
168189
169- # NT-16 : Missing required top-level key (directions)
190+ # NT-19 : Missing required top-level key (directions)
170191F=$( make_fixture " missing-directions-key" ' del(.directions)' )
171192EXIT_CODE=0
172193run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
173194[[ $EXIT_CODE -ne 0 ]] && pass " missing .directions key: exits non-zero" \
174195 || fail " missing .directions key: exits non-zero" " non-zero" " $EXIT_CODE "
175196
176- # NT-17 : Missing required top-level key (title)
197+ # NT-20 : Missing required top-level key (title)
177198F=$( make_fixture " missing-title-key" ' del(.title)' )
178199EXIT_CODE=0
179200run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
180201[[ $EXIT_CODE -ne 0 ]] && pass " missing .title key: exits non-zero" \
181202 || fail " missing .title key: exits non-zero" " non-zero" " $EXIT_CODE "
182203
183- # NT-18 : Missing required top-level key (original_idea)
204+ # NT-21 : Missing required top-level key (original_idea)
184205F=$( make_fixture " missing-original-idea" ' del(.original_idea)' )
185206EXIT_CODE=0
186207run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
187208[[ $EXIT_CODE -ne 0 ]] && pass " missing .original_idea key: exits non-zero" \
188209 || fail " missing .original_idea key: exits non-zero" " non-zero" " $EXIT_CODE "
189210
190- # NT-19 : Missing required top-level key (metadata)
211+ # NT-22 : Missing required top-level key (metadata)
191212F=$( make_fixture " missing-metadata" ' del(.metadata)' )
192213EXIT_CODE=0
193214run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
194215[[ $EXIT_CODE -ne 0 ]] && pass " missing .metadata key: exits non-zero" \
195216 || fail " missing .metadata key: exits non-zero" " non-zero" " $EXIT_CODE "
196217
197- # NT-20 : Missing direction_id (per-direction required field)
218+ # NT-23 : Missing direction_id (per-direction required field)
198219F=$( make_fixture " missing-direction-id" ' .directions[0] |= del(.direction_id)' )
199220EXIT_CODE=0
200221run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
201222[[ $EXIT_CODE -ne 0 ]] && pass " missing direction_id: exits non-zero" \
202223 || fail " missing direction_id: exits non-zero" " non-zero" " $EXIT_CODE "
203224
204- # NT-21 : source_index is a string (not integer)
225+ # NT-24 : source_index is a string (not integer)
205226F=$( make_fixture " source-index-string" ' .directions[0].source_index = "0"' )
206227EXIT_CODE=0
207228run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
208229[[ $EXIT_CODE -ne 0 ]] && pass " string source_index: exits non-zero" \
209230 || fail " string source_index: exits non-zero" " non-zero" " $EXIT_CODE "
210231
211- # NT-22 : title is not a string (numeric type)
232+ # NT-25 : title is not a string (numeric type)
212233F=$( make_fixture " title-numeric" ' .title = 123' )
213234EXIT_CODE=0
214235run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
215236[[ $EXIT_CODE -ne 0 ]] && pass " numeric title: exits non-zero" \
216237 || fail " numeric title: exits non-zero" " non-zero" " $EXIT_CODE "
217238
218- # NT-23 : objective_evidence items are not strings (numeric array)
239+ # NT-26 : objective_evidence items are not strings (numeric array)
219240F=$( make_fixture " evidence-items-numeric" ' .directions[0].objective_evidence = [1, 2]' )
220241EXIT_CODE=0
221242run_validate " $F " > /dev/null 2>&1 || EXIT_CODE=$?
0 commit comments