Skip to content

Commit

Permalink
Merge pull request #4 from appfolio/remove_af_testing
Browse files Browse the repository at this point in the history
Remove `af_testing`, update `minitest`
  • Loading branch information
Maimer authored Nov 6, 2021
2 parents ad3bda4 + d882c10 commit 125648f
Show file tree
Hide file tree
Showing 7 changed files with 23 additions and 42 deletions.
7 changes: 4 additions & 3 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
# frozen_string_literal: true

source 'https://rubygems.org'

source 'https://rubygems.org' do
gem 'minitest', '>= 5.8', '< 6'
gem 'minitest', '>= 5.14', '< 6'
gem 'minitest-reporters', '>= 1.4', '< 2'
gem 'simplecov', '>= 0.18', '< 1', group: :test, require: false
gem 'simplecov', '>= 0.21', '< 1', group: :test, require: false
end

source 'https://rubygems.pkg.github.com/appfolio' do
gem 'af_gems', '>= 9.2', '< 10', group: :development
gem 'af_testing', '>= 14.4', '< 15'
end

gemspec
7 changes: 4 additions & 3 deletions gemfiles/ruby_2.6.3_rails60.gemfile
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
# This file was generated by Appraisal

source "https://rubygems.org"

source "https://rubygems.org" do
gem "minitest", ">= 5.8", "< 6"
gem "minitest", ">= 5.14", "< 6"
gem "minitest-reporters", ">= 1.4", "< 2"
gem "simplecov", ">= 0.18", "< 1", group: :test, require: false
gem "simplecov", ">= 0.21", "< 1", group: :test, require: false
gem "rails", "~> 6.0.0"
end

source "https://rubygems.pkg.github.com/appfolio" do
gem "af_gems", ">= 9.2", "< 10", group: :development
gem "af_testing", ">= 14.4", "< 15"
end

gemspec path: "../"
7 changes: 4 additions & 3 deletions gemfiles/ruby_2.6.3_rails61.gemfile
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
# This file was generated by Appraisal

source "https://rubygems.org"

source "https://rubygems.org" do
gem "minitest", ">= 5.8", "< 6"
gem "minitest", ">= 5.14", "< 6"
gem "minitest-reporters", ">= 1.4", "< 2"
gem "simplecov", ">= 0.18", "< 1", group: :test, require: false
gem "simplecov", ">= 0.21", "< 1", group: :test, require: false
gem "rails", "~> 6.1.0"
end

source "https://rubygems.pkg.github.com/appfolio" do
gem "af_gems", ">= 9.2", "< 10", group: :development
gem "af_testing", ">= 14.4", "< 15"
end

gemspec path: "../"
7 changes: 4 additions & 3 deletions gemfiles/ruby_2.7.1_rails60.gemfile
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
# This file was generated by Appraisal

source "https://rubygems.org"

source "https://rubygems.org" do
gem "minitest", ">= 5.8", "< 6"
gem "minitest", ">= 5.14", "< 6"
gem "minitest-reporters", ">= 1.4", "< 2"
gem "simplecov", ">= 0.18", "< 1", group: :test, require: false
gem "simplecov", ">= 0.21", "< 1", group: :test, require: false
gem "rails", "~> 6.0.0"
end

source "https://rubygems.pkg.github.com/appfolio" do
gem "af_gems", ">= 9.2", "< 10", group: :development
gem "af_testing", ">= 14.4", "< 15"
end

gemspec path: "../"
7 changes: 4 additions & 3 deletions gemfiles/ruby_2.7.1_rails61.gemfile
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
# This file was generated by Appraisal

source "https://rubygems.org"

source "https://rubygems.org" do
gem "minitest", ">= 5.8", "< 6"
gem "minitest", ">= 5.14", "< 6"
gem "minitest-reporters", ">= 1.4", "< 2"
gem "simplecov", ">= 0.18", "< 1", group: :test, require: false
gem "simplecov", ">= 0.21", "< 1", group: :test, require: false
gem "rails", "~> 6.1.0"
end

source "https://rubygems.pkg.github.com/appfolio" do
gem "af_gems", ">= 9.2", "< 10", group: :development
gem "af_testing", ">= 14.4", "< 15"
end

gemspec path: "../"
27 changes: 2 additions & 25 deletions test/dsig_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
require 'base64'

class DsigTest < Minitest::Test
def _test_generate_key #very slow so not run by default
def test_generate_key #very slow so not run by default
signer=EzCrypto::Signer.generate
assert signer.rsa?
assert !signer.dsa?
Expand Down Expand Up @@ -243,7 +243,7 @@ def test_load_trusted_truststore
sf_root=EzCrypto::Verifier.from_file File.dirname(__FILE__) + "/sf-class2-root.crt"
assert trust.verify(sf_root)
starfield=EzCrypto::Verifier.from_file File.dirname(__FILE__) + "/sf_intermediate.crt"
assert trust.verify(starfield) if AfTesting.circle_ci?
assert trust.verify(starfield) if ENV.key?('CIRCLECI')
agree2=EzCrypto::Verifier.from_file File.dirname(__FILE__) + "/agree2.com.cert"
# DSS1 was dropped from OpenSSL in version 1.1
refute trust.verify(agree2)
Expand All @@ -255,29 +255,6 @@ def test_load_trusted_truststore
refute trust.verify(cert)
end

# Disabling these until pkyp is back up
# def test_public_key_load_from_pkyp
# verifier=EzCrypto::Verifier.from_pkyp "e93e18114cbefaaa89fda908b09df63d3662879a"
# agree2=EzCrypto::Verifier.from_file File.dirname(__FILE__) + "/agree2.com.cert"
# assert_equal agree2.cert.to_s,verifier.cert.to_s
# assert verifier
# end
#
# def test_register_public_key_at_pkyp
# pub=EzCrypto::Verifier.from_file File.dirname(__FILE__) + "/agree2.com.cert"
# assert_equal pub.digest,pub.register_with_pkyp
# end
#
# def test_create_register_and_fetch_public_key
# signer=EzCrypto::Signer.generate
# assert_equal signer.verifier.digest,signer.verifier.register_with_pkyp
# verifier=EzCrypto::Verifier.from_pkyp signer.verifier.digest
# sig=signer.sign "hello"
# assert sig
# assert verifier.verify( sig,"hello")
# end
#

def assert_signer(signer)
assert signer
assert signer.public_key
Expand Down
3 changes: 1 addition & 2 deletions test/test_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,7 @@
end
end

require 'af_testing/mini_test'
require 'minitest/autorun'
require 'minitest/reporters'

MiniTest::Reporters.use!
MiniTest::Reporters.use! unless ENV['RM_INFO']

0 comments on commit 125648f

Please sign in to comment.