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.
2 parents 716b408 + 3bc0c6b commit 3babab2Copy full SHA for 3babab2
Library/Homebrew/test/checksum_spec.rb
@@ -0,0 +1,19 @@
1
+require "checksum"
2
+
3
+describe Checksum do
4
+ describe "#empty?" do
5
+ subject { described_class.new(:sha256, "") }
6
+ it { is_expected.to be_empty }
7
+ end
8
9
+ describe "#==" do
10
+ subject { described_class.new(:sha256, TEST_SHA256) }
11
+ let(:other) { described_class.new(:sha256, TEST_SHA256) }
12
+ let(:other_reversed) { described_class.new(:sha256, TEST_SHA256.reverse) }
13
+ let(:other_sha1) { described_class.new(:sha1, TEST_SHA1) }
14
15
+ it { is_expected.to eq(other) }
16
+ it { is_expected.not_to eq(other_reversed) }
17
+ it { is_expected.not_to eq(other_sha1) }
18
19
+end
Library/Homebrew/test/checksum_test.rb
0 commit comments