Restores spec/lib/fingerprint_self_test_spec.rb that was previously removed during the repo split. The fingerprint self tests are more detailed than the checks performed by recog_verify, and should always be run to test fingerprint updates. The test file and spec/spec_helper.rb were modified so that the test could also run from within the recog-ruby repo.
Diff against last version before the repo split
--- a/spec/lib/fingerprint_self_test_spec.rb.fac7d6d6688330b155fd35f80eacc920ec9db75e
+++ b/spec/lib/fingerprint_self_test_spec.rb
@@ -3,8 +3,8 @@ require 'regexp_parser'
require 'nokogiri'
describe Recog::DB do
- let(:schema) { Nokogiri::XML::Schema(open(File.expand_path(File.join(%w(xml fingerprints.xsd))))) }
- Dir[File.expand_path File.join('xml', '*.xml')].each do |xml_file_name|
+ let(:schema) { Nokogiri::XML::Schema(open(File.join(FINGERPRINT_DIR, 'fingerprints.xsd'))) }
+ Dir[File.join(FINGERPRINT_DIR, '*.xml')].each do |xml_file_name|
describe "##{File.basename(xml_file_name)}" do
@@ -172,4 +172,4 @@ describe Recog::DB do
end
end
-end
\ No newline at end of file
+end
Motivation and Context
To ensure that fingerprint quality is maintained.
How Has This Been Tested?
rake tests
rake spec
rspec
Same steps above run from the development branch for rapid7/recog-ruby#3
Types of changes
Bug fix (non-breaking change which fixes an issue)
New feature (non-breaking change which adds functionality)
Checklist:
[x] I have updated the documentation accordingly (or changes are not required).
[x] I have added tests to cover my changes (or new tests are not required).
Description
Restores
spec/lib/fingerprint_self_test_spec.rb
that was previously removed during the repo split. The fingerprint self tests are more detailed than the checks performed byrecog_verify
, and should always be run to test fingerprint updates. The test file andspec/spec_helper.rb
were modified so that the test could also run from within the recog-ruby repo.Diff against last version before the repo split
Motivation and Context
To ensure that fingerprint quality is maintained.
How Has This Been Tested?
rake tests
rake spec
rspec
Types of changes
Checklist: