diff options
author | elijah <elijah@riseup.net> | 2013-03-06 01:34:16 -0800 |
---|---|---|
committer | elijah <elijah@riseup.net> | 2013-03-06 01:34:16 -0800 |
commit | 886585a0f673e0ea70abb99504ff9c70180361d5 (patch) | |
tree | 38ba46eb1eb277410a96a1cb3da70715fdfe8d6c /certs/test/unit | |
parent | f0ffc65aa38473ef280ed80526691d588f14c8de (diff) |
certs - changed the logic of free/paid certs to be limited/unlimited.
Diffstat (limited to 'certs/test/unit')
-rw-r--r-- | certs/test/unit/client_certificate_test.rb | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/certs/test/unit/client_certificate_test.rb b/certs/test/unit/client_certificate_test.rb index abb5560..036e724 100644 --- a/certs/test/unit/client_certificate_test.rb +++ b/certs/test/unit/client_certificate_test.rb @@ -9,18 +9,12 @@ class ClientCertificateTest < ActiveSupport::TestCase assert sample.to_s end - test "free cert has configured prefix" do - sample = ClientCertificate.new(free: true) - prefix = APP_CONFIG[:free_cert_prefix] + test "cert has configured prefix" do + prefix = "PREFIX" + sample = ClientCertificate.new(:prefix => prefix) assert sample.cert.subject.common_name.starts_with?(prefix) end - test "real cert has no free cert prefix" do - sample = ClientCertificate.new - prefix = APP_CONFIG[:free_cert_prefix] - assert !sample.cert.subject.common_name.starts_with?(prefix) - end - test "cert issuer matches ca subject" do sample = ClientCertificate.new cert = OpenSSL::X509::Certificate.new(sample.cert.to_pem) |