diff --git a/internal/stage_wildcard.go b/internal/stage_wildcard.go index ff0cd35..690cf75 100644 --- a/internal/stage_wildcard.go +++ b/internal/stage_wildcard.go @@ -11,21 +11,21 @@ func testWildcard(stageHarness *test_case_harness.TestCaseHarness) error { Input: "cat", ExpectedExitCode: 0, }, - { - Pattern: "c.t", - Input: "cot", - ExpectedExitCode: 0, - }, { Pattern: "c.t", Input: "car", ExpectedExitCode: 1, }, { - Pattern: "c.+t", - Input: "coat", + Pattern: "g.+gol", + Input: "goøö0Ogol", ExpectedExitCode: 0, }, + { + Pattern: "g.+gol", + Input: "gol", + ExpectedExitCode: 1, + }, } return RunTestCases(testCases, stageHarness) diff --git a/internal/test_helpers/fixtures/alternation/success b/internal/test_helpers/fixtures/alternation/success index 83790d9..2411576 100644 --- a/internal/test_helpers/fixtures/alternation/success +++ b/internal/test_helpers/fixtures/alternation/success @@ -13,14 +13,13 @@ [stage-11] $ echo -n "cat" | ./your_grep.sh -E "c.t" [your_program] cat [stage-11] ✓ Received exit code 0. -[stage-11] $ echo -n "cot" | ./your_grep.sh -E "c.t" -[your_program] cot -[stage-11] ✓ Received exit code 0. [stage-11] $ echo -n "car" | ./your_grep.sh -E "c.t" [stage-11] ✓ Received exit code 1. -[stage-11] $ echo -n "coat" | ./your_grep.sh -E "c.+t" -[your_program] coat +[stage-11] $ echo -n "goøö0Ogol" | ./your_grep.sh -E "g.+gol" +[your_program] goøö0Ogol [stage-11] ✓ Received exit code 0. +[stage-11] $ echo -n "gol" | ./your_grep.sh -E "g.+gol" +[stage-11] ✓ Received exit code 1. [stage-11] Test passed. [stage-10] Running tests for Stage #10: ny8 diff --git a/internal/test_helpers/fixtures/backreferences_multiple/success b/internal/test_helpers/fixtures/backreferences_multiple/success index acc46f9..a4f0129 100644 --- a/internal/test_helpers/fixtures/backreferences_multiple/success +++ b/internal/test_helpers/fixtures/backreferences_multiple/success @@ -95,14 +95,13 @@ [stage-11] $ echo -n "cat" | ./your_grep.sh -E "c.t" [your_program] cat [stage-11] ✓ Received exit code 0. -[stage-11] $ echo -n "cot" | ./your_grep.sh -E "c.t" -[your_program] cot -[stage-11] ✓ Received exit code 0. [stage-11] $ echo -n "car" | ./your_grep.sh -E "c.t" [stage-11] ✓ Received exit code 1. -[stage-11] $ echo -n "coat" | ./your_grep.sh -E "c.+t" -[your_program] coat +[stage-11] $ echo -n "goøö0Ogol" | ./your_grep.sh -E "g.+gol" +[your_program] goøö0Ogol [stage-11] ✓ Received exit code 0. +[stage-11] $ echo -n "gol" | ./your_grep.sh -E "g.+gol" +[stage-11] ✓ Received exit code 1. [stage-11] Test passed. [stage-10] Running tests for Stage #10: ny8 diff --git a/internal/test_helpers/fixtures/backreferences_nested/success b/internal/test_helpers/fixtures/backreferences_nested/success index 17b62b0..274eab6 100644 --- a/internal/test_helpers/fixtures/backreferences_nested/success +++ b/internal/test_helpers/fixtures/backreferences_nested/success @@ -136,14 +136,13 @@ [stage-11] $ echo -n "cat" | ./your_grep.sh -E "c.t" [your_program] cat [stage-11] ✓ Received exit code 0. -[stage-11] $ echo -n "cot" | ./your_grep.sh -E "c.t" -[your_program] cot -[stage-11] ✓ Received exit code 0. [stage-11] $ echo -n "car" | ./your_grep.sh -E "c.t" [stage-11] ✓ Received exit code 1. -[stage-11] $ echo -n "coat" | ./your_grep.sh -E "c.+t" -[your_program] coat +[stage-11] $ echo -n "goøö0Ogol" | ./your_grep.sh -E "g.+gol" +[your_program] goøö0Ogol [stage-11] ✓ Received exit code 0. +[stage-11] $ echo -n "gol" | ./your_grep.sh -E "g.+gol" +[stage-11] ✓ Received exit code 1. [stage-11] Test passed. [stage-10] Running tests for Stage #10: ny8 diff --git a/internal/test_helpers/fixtures/backreferences_single/success b/internal/test_helpers/fixtures/backreferences_single/success index e7dad93..9f15e21 100644 --- a/internal/test_helpers/fixtures/backreferences_single/success +++ b/internal/test_helpers/fixtures/backreferences_single/success @@ -54,14 +54,13 @@ [stage-11] $ echo -n "cat" | ./your_grep.sh -E "c.t" [your_program] cat [stage-11] ✓ Received exit code 0. -[stage-11] $ echo -n "cot" | ./your_grep.sh -E "c.t" -[your_program] cot -[stage-11] ✓ Received exit code 0. [stage-11] $ echo -n "car" | ./your_grep.sh -E "c.t" [stage-11] ✓ Received exit code 1. -[stage-11] $ echo -n "coat" | ./your_grep.sh -E "c.+t" -[your_program] coat +[stage-11] $ echo -n "goøö0Ogol" | ./your_grep.sh -E "g.+gol" +[your_program] goøö0Ogol [stage-11] ✓ Received exit code 0. +[stage-11] $ echo -n "gol" | ./your_grep.sh -E "g.+gol" +[stage-11] ✓ Received exit code 1. [stage-11] Test passed. [stage-10] Running tests for Stage #10: ny8 diff --git a/internal/test_helpers/fixtures/wildcard/success b/internal/test_helpers/fixtures/wildcard/success index 8de626e..ad7f8ef 100644 --- a/internal/test_helpers/fixtures/wildcard/success +++ b/internal/test_helpers/fixtures/wildcard/success @@ -2,14 +2,13 @@ [stage-11] $ echo -n "cat" | ./your_grep.sh -E "c.t" [your_program] cat [stage-11] ✓ Received exit code 0. -[stage-11] $ echo -n "cot" | ./your_grep.sh -E "c.t" -[your_program] cot -[stage-11] ✓ Received exit code 0. [stage-11] $ echo -n "car" | ./your_grep.sh -E "c.t" [stage-11] ✓ Received exit code 1. -[stage-11] $ echo -n "coat" | ./your_grep.sh -E "c.+t" -[your_program] coat +[stage-11] $ echo -n "goøö0Ogol" | ./your_grep.sh -E "g.+gol" +[your_program] goøö0Ogol [stage-11] ✓ Received exit code 0. +[stage-11] $ echo -n "gol" | ./your_grep.sh -E "g.+gol" +[stage-11] ✓ Received exit code 1. [stage-11] Test passed. [stage-10] Running tests for Stage #10: ny8