We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8d2ab95 commit 4181903Copy full SHA for 4181903
spec/unit/differ_spec.rb
@@ -2,14 +2,22 @@
2
3
RSpec.describe SuperDiff::Differ do
4
describe "#call" do
5
- context "given the same number" do
+ context "given the same integers" do
6
it "returns an empty string" do
7
output = described_class.call(expected: 1, actual: 1)
8
9
expect(output).to eq("")
10
end
11
12
13
+ context "given the same numbers (even if they're different types)" do
14
+ it "returns an empty string" do
15
+ output = described_class.call(expected: 1, actual: 1.0)
16
+
17
+ expect(output).to eq("")
18
+ end
19
20
21
context "given differing numbers" do
22
it "returns a message along with a comparison" do
23
actual_output = described_class.call(expected: 42, actual: 1)
0 commit comments