File tree Expand file tree Collapse file tree 4 files changed +29
-0
lines changed
Expand file tree Collapse file tree 4 files changed +29
-0
lines changed Original file line number Diff line number Diff line change @@ -45,3 +45,6 @@ description = "cross"
4545
4646[dd9d4ca8-9e68-4f78-a677-a2a70fd7a7b8 ]
4747description = " large garden"
48+
49+ [6e4ac13a-3e43-4728-a2e3-3551d4b1a996 ]
50+ description = " multiple adjacent flowers"
Original file line number Diff line number Diff line change @@ -187,3 +187,9 @@ join() {
187187 assert_output " $( join " ${expected[@]} " ) "
188188}
189189
190+ @test " multiple adjacent flowers" {
191+ [[ $BATS_RUN_SKIPPED == " true" ]] || skip
192+ run bash flower_field.sh " ** "
193+ assert_success
194+ assert_output " 1**1"
195+ }
Original file line number Diff line number Diff line change @@ -30,6 +30,12 @@ description = "invalid character in isbn is not treated as zero"
3030[28025280-2c39-4092-9719-f3234b89c627 ]
3131description = " X is only valid as a check digit"
3232
33+ [8005b57f-f194-44ee-88d2-a77ac4142591 ]
34+ description = " only one check digit is allowed"
35+
36+ [fdb14c99-4cf8-43c5-b06d-eb1638eff343 ]
37+ description = " X is not substituted by the value 10"
38+
3339[f6294e61-7e79-46b3-977b-f48789a4945b ]
3440description = " valid isbn without separating dashes"
3541
Original file line number Diff line number Diff line change @@ -52,6 +52,20 @@ load bats-extra
5252 assert_output " false"
5353}
5454
55+ @test ' only one check digit is allowed' {
56+ [[ $BATS_RUN_SKIPPED == " true" ]] || skip
57+ run bash isbn_verifier.sh ' 3-598-21508-96'
58+ assert_success
59+ assert_output " false"
60+ }
61+
62+ @test ' X is not substituted by the value 10' {
63+ [[ $BATS_RUN_SKIPPED == " true" ]] || skip
64+ run bash isbn_verifier.sh ' 3-598-2X507-5'
65+ assert_success
66+ assert_output " false"
67+ }
68+
5569@test ' valid isbn without separating dashes' {
5670 [[ $BATS_RUN_SKIPPED == " true" ]] || skip
5771 run bash isbn_verifier.sh ' 3598215088'
You can’t perform that action at this time.
0 commit comments