spec/fernet_spec.rb in fernet-1.3 vs spec/fernet_spec.rb in fernet-1.4

- old
+ new

@@ -133,6 +133,16 @@ Fernet.verify(secret, token) do |verifier| verifier.data['password'].should == 'password1' end end + + it 'returns the unencrypted message upon verify' do + token = Fernet.generate(secret) do |generator| + generator.data['password'] = 'password1' + end + + verifier = Fernet.verifier(secret, token) + verifier.should be_valid + verifier.data['password'].should == 'password1' + end end