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 f9e6a23 commit edb3da0Copy full SHA for edb3da0
library/openssl/digest/name_spec.rb
@@ -0,0 +1,16 @@
1
+require_relative '../../../spec_helper'
2
+require 'openssl'
3
+
4
+describe "OpenSSL::Digest#name" do
5
+ it "returns the name of digest when called on an instance" do
6
+ OpenSSL::Digest.new('SHA1').name.should == 'SHA1'
7
+ end
8
9
+ it "converts the name to the internal representation of OpenSSL" do
10
+ OpenSSL::Digest.new('sha1').name.should == 'SHA1'
11
12
13
+ it "works on subclasses too" do
14
+ OpenSSL::Digest::SHA1.new.name.should == 'SHA1'
15
16
+end
0 commit comments