Last active
June 5, 2022 16:12
-
-
Save dorianmariecom/e6eef1393b6d684bb3300613efac7da8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
~/s/language> crystal a.rb | |
FF | |
Failures: | |
1) Hash(K, V) equals with symbol | |
Failure/Error: { :a => 1 }.should eq({ a: 1 }) | |
Expected: {a: 1} | |
got: {:a => 1} | |
# a.rb:5 | |
2) Hash(K, V) equals with string | |
Failure/Error: { "a" => 1 }.should eq({ a: 1 }) | |
Expected: {a: 1} | |
got: {"a" => 1} | |
# a.rb:9 | |
Finished in 267 microseconds | |
2 examples, 2 failures, 0 errors, 0 pending | |
Failed examples: | |
crystal spec a.rb:4 # Hash(K, V) equals with symbol | |
crystal spec a.rb:8 # Hash(K, V) equals with string |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require "spec" | |
describe Hash do | |
it "equals with symbol" do | |
{ :a => 1 }.should eq({ a: 1 }) | |
end | |
it "equals with string" do | |
{ "a" => 1 }.should eq({ a: 1 }) | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment