diff --git a/spec/oq_spec.cr b/spec/oq_spec.cr index 9e4b4a3..28218b0 100644 --- a/spec/oq_spec.cr +++ b/spec/oq_spec.cr @@ -37,7 +37,10 @@ describe OQ do it "should colorize the output with the -C option" do run_binary(input: SIMPLE_JSON_OBJECT, args: ["-c", "-C", "."]) do |output| - output.should eq %(\e[1;39m{\e[0m\e[34;1m"name"\e[0m\e[1;39m:\e[0m\e[0;32m"Jim"\e[0m\e[1;39m\e[1;39m}\e[0m\n) + output.should start_with "\e" + output.should contain %("name") + output.should contain %("Jim") + output.should end_with "\e[0m\n" end end diff --git a/spec/processor_spec.cr b/spec/processor_spec.cr index 0b20706..77b5e6d 100644 --- a/spec/processor_spec.cr +++ b/spec/processor_spec.cr @@ -21,7 +21,7 @@ describe OQ::Processor do end output_io.to_s.should be_empty - error_io.to_s.should eq "parse error: Invalid numeric literal at line 1, column 12\n" + error_io.to_s.should contain "parse error: Invalid numeric literal at line 1, column 12\n" end describe "file input" do