Initial import of ruby-approvaltests, an assertion/verification library
to aid testing. This is the Ruby port of ApprovalTests. You can use ApprovalTests to verify objects that require more than a simple assert including long strings, large arrays, and complex hash structures and objects. ApprovalTests really shines when you need a more granular look at the test failure. Sometimes, trying to find a small difference in a long string printed to STDOUT is just too hard! ApprovalTests solves this problem by providing reporters which let you view the test results in one of many popular diff utilities.
This commit is contained in:
parent
445144aef1
commit
b90a371cb1
4 changed files with 160 additions and 0 deletions
10
devel/ruby-approvaltests/DESCR
Normal file
10
devel/ruby-approvaltests/DESCR
Normal file
|
@ -0,0 +1,10 @@
|
|||
`approvaltests` is the Ruby port of ApprovalTests, an open source
|
||||
assertion/verification library to aid testing.
|
||||
|
||||
You can use ApprovalTests to verify objects that require more than a
|
||||
simple assert including long strings, large arrays, and complex hash
|
||||
structures and objects. ApprovalTests really shines when you need a more
|
||||
granular look at the test failure. Sometimes, trying to find a small
|
||||
difference in a long string printed to STDOUT is just too hard!
|
||||
ApprovalTests solves this problem by providing reporters which let you
|
||||
view the test results in one of many popular diff utilities.
|
25
devel/ruby-approvaltests/Makefile
Normal file
25
devel/ruby-approvaltests/Makefile
Normal file
|
@ -0,0 +1,25 @@
|
|||
# $NetBSD: Makefile,v 1.1 2021/06/07 19:55:27 schmonz Exp $
|
||||
|
||||
DISTNAME= approvals-0.0.25
|
||||
PKGNAME= ${RUBY_PKGPREFIX}-${DISTNAME:S/approvals/approvaltests/}
|
||||
CATEGORIES= devel
|
||||
|
||||
MAINTAINER= schmonz@NetBSD.org
|
||||
HOMEPAGE= https://approvaltests.com/
|
||||
COMMENT= Assertion/verification library to aid testing
|
||||
LICENSE= mit
|
||||
|
||||
DEPENDS+= ${RUBY_PKGPREFIX}-json>=2.0:../../textproc/ruby-json
|
||||
DEPENDS+= ${RUBY_PKGPREFIX}-nokogiri>=1.8:../../textproc/ruby-nokogiri
|
||||
DEPENDS+= ${RUBY_PKGPREFIX}-thor>=1.0:../../devel/ruby-thor
|
||||
|
||||
RUBYGEM_OPTIONS+= --format-executable
|
||||
|
||||
SUBST_CLASSES+= jsondep
|
||||
SUBST_STAGE.jsondep= pre-configure
|
||||
SUBST_FILES.jsondep= ${WRKDIR}/${DISTNAME}.gemspec
|
||||
SUBST_SED.jsondep= -e 's|, "ext/mkrf_conf.rb".freeze||'
|
||||
SUBST_SED.jsondep+= -e 's|"ext/mkrf_conf.rb".freeze||'
|
||||
|
||||
.include "../../lang/ruby/gem.mk"
|
||||
.include "../../mk/bsd.pkg.mk"
|
119
devel/ruby-approvaltests/PLIST
Normal file
119
devel/ruby-approvaltests/PLIST
Normal file
|
@ -0,0 +1,119 @@
|
|||
@comment $NetBSD: PLIST,v 1.1 2021/06/07 19:55:27 schmonz Exp $
|
||||
bin/approvals${RUBY_SUFFIX}
|
||||
${GEM_HOME}/cache/${GEM_NAME}.gem
|
||||
${GEM_LIBDIR}/.gitignore
|
||||
${GEM_LIBDIR}/.travis.yml
|
||||
${GEM_LIBDIR}/CHANGELOG.md
|
||||
${GEM_LIBDIR}/Gemfile
|
||||
${GEM_LIBDIR}/License.txt
|
||||
${GEM_LIBDIR}/README.md
|
||||
${GEM_LIBDIR}/Rakefile
|
||||
${GEM_LIBDIR}/approvals.gemspec
|
||||
${GEM_LIBDIR}/bin/approvals
|
||||
${GEM_LIBDIR}/lib/approvals.rb
|
||||
${GEM_LIBDIR}/lib/approvals/approval.rb
|
||||
${GEM_LIBDIR}/lib/approvals/cli.rb
|
||||
${GEM_LIBDIR}/lib/approvals/configuration.rb
|
||||
${GEM_LIBDIR}/lib/approvals/dotfile.rb
|
||||
${GEM_LIBDIR}/lib/approvals/dsl.rb
|
||||
${GEM_LIBDIR}/lib/approvals/error.rb
|
||||
${GEM_LIBDIR}/lib/approvals/executable.rb
|
||||
${GEM_LIBDIR}/lib/approvals/extensions/rspec.rb
|
||||
${GEM_LIBDIR}/lib/approvals/extensions/rspec/dsl.rb
|
||||
${GEM_LIBDIR}/lib/approvals/filter.rb
|
||||
${GEM_LIBDIR}/lib/approvals/namers/default_namer.rb
|
||||
${GEM_LIBDIR}/lib/approvals/namers/directory_namer.rb
|
||||
${GEM_LIBDIR}/lib/approvals/namers/rspec_namer.rb
|
||||
${GEM_LIBDIR}/lib/approvals/reporters.rb
|
||||
${GEM_LIBDIR}/lib/approvals/reporters/diff_reporter/diffmerge_reporter.rb
|
||||
${GEM_LIBDIR}/lib/approvals/reporters/diff_reporter/opendiff_reporter.rb
|
||||
${GEM_LIBDIR}/lib/approvals/reporters/diff_reporter/tortoisediff_reporter.rb
|
||||
${GEM_LIBDIR}/lib/approvals/reporters/diff_reporter/vimdiff_reporter.rb
|
||||
${GEM_LIBDIR}/lib/approvals/reporters/filelauncher_reporter.rb
|
||||
${GEM_LIBDIR}/lib/approvals/reporters/first_working_reporter.rb
|
||||
${GEM_LIBDIR}/lib/approvals/reporters/image_reporter.rb
|
||||
${GEM_LIBDIR}/lib/approvals/reporters/image_reporter/html_image_reporter.rb
|
||||
${GEM_LIBDIR}/lib/approvals/reporters/image_reporter/image_magick_reporter.rb
|
||||
${GEM_LIBDIR}/lib/approvals/reporters/launcher.rb
|
||||
${GEM_LIBDIR}/lib/approvals/reporters/reporter.rb
|
||||
${GEM_LIBDIR}/lib/approvals/rspec.rb
|
||||
${GEM_LIBDIR}/lib/approvals/scrubber.rb
|
||||
${GEM_LIBDIR}/lib/approvals/system_command.rb
|
||||
${GEM_LIBDIR}/lib/approvals/verifier.rb
|
||||
${GEM_LIBDIR}/lib/approvals/verifiers/json_verifier.rb
|
||||
${GEM_LIBDIR}/lib/approvals/version.rb
|
||||
${GEM_LIBDIR}/lib/approvals/writer.rb
|
||||
${GEM_LIBDIR}/lib/approvals/writers/array_writer.rb
|
||||
${GEM_LIBDIR}/lib/approvals/writers/binary_writer.rb
|
||||
${GEM_LIBDIR}/lib/approvals/writers/hash_writer.rb
|
||||
${GEM_LIBDIR}/lib/approvals/writers/html_writer.rb
|
||||
${GEM_LIBDIR}/lib/approvals/writers/json_writer.rb
|
||||
${GEM_LIBDIR}/lib/approvals/writers/text_writer.rb
|
||||
${GEM_LIBDIR}/lib/approvals/writers/xml_writer.rb
|
||||
${GEM_LIBDIR}/spec/approvals_spec.rb
|
||||
${GEM_LIBDIR}/spec/configuration_spec.rb
|
||||
${GEM_LIBDIR}/spec/dotfile_spec.rb
|
||||
${GEM_LIBDIR}/spec/executable_spec.rb
|
||||
${GEM_LIBDIR}/spec/extensions/rspec_approvals_spec.rb
|
||||
${GEM_LIBDIR}/spec/filter_spec.rb
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_custom_writer_verifies_a_complex_object.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_ignores_whitespace_differences_in_json.approved.json
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_passes_approved_files_through_erb.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_passes_the_received_files_through_erb.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_supports_excluded_keys_option_also_supports_an_array_of_hashes.approved.json
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_supports_excluded_keys_option_supports_the_array_writer.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_supports_excluded_keys_option_supports_the_hash_writer.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_supports_excluded_keys_option_verifies_json_with_excluded_keys.approved.json
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_verifies_a_complex_object.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_verifies_a_hash.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_verifies_a_malformed_html_fragment.approved.html
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_verifies_a_string.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_verifies_an_array.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_verifies_an_array_as_json_when_format_is_set_to_json.approved.json
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_verifies_an_executable.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_verifies_html.approved.html
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_verifies_json.approved.json
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_verifies_json_and_is_newline_agnostic.approved.json
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_verifies_json_with_a_time_object.approved.json
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/approvals_verifies_xml.approved.xml
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifications_a_string.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_a_complex_object.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_a_failure.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_a_failure_diff.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_a_string.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_an_array.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_an_executable.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_directory/a_complex_object.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_directory/a_failure.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_directory/a_failure_diff.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_directory/a_string.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_directory/an_array.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_directory/an_executable.approved.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_directory/html.approved.html
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_directory/json.approved.json
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_directory/xml.approved.xml
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_html.approved.html
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_json.approved.json
|
||||
${GEM_LIBDIR}/spec/fixtures/approvals/verifies_xml.approved.xml
|
||||
${GEM_LIBDIR}/spec/fixtures/json_approval_with_different_whitespace/approved.json
|
||||
${GEM_LIBDIR}/spec/fixtures/json_approval_with_different_whitespace/received.json
|
||||
${GEM_LIBDIR}/spec/fixtures/json_approval_with_different_whitespace/received_different_content.json
|
||||
${GEM_LIBDIR}/spec/fixtures/one.png
|
||||
${GEM_LIBDIR}/spec/fixtures/one.txt
|
||||
${GEM_LIBDIR}/spec/fixtures/two.png
|
||||
${GEM_LIBDIR}/spec/fixtures/two.txt
|
||||
${GEM_LIBDIR}/spec/namers/default_namer_spec.rb
|
||||
${GEM_LIBDIR}/spec/namers/directory_namer_spec.rb
|
||||
${GEM_LIBDIR}/spec/namers/rspec_namer_spec.rb
|
||||
${GEM_LIBDIR}/spec/namers_spec.rb
|
||||
${GEM_LIBDIR}/spec/reporters/first_working_reporter_spec.rb
|
||||
${GEM_LIBDIR}/spec/reporters/html_image_reporter_spec.rb
|
||||
${GEM_LIBDIR}/spec/reporters/image_magick_reporter_spec.rb
|
||||
${GEM_LIBDIR}/spec/reporters/launcher_spec.rb
|
||||
${GEM_LIBDIR}/spec/reporters/opendiff_reporter_spec.rb
|
||||
${GEM_LIBDIR}/spec/reporters/reporter_spec.rb
|
||||
${GEM_LIBDIR}/spec/scrubber_spec.rb
|
||||
${GEM_LIBDIR}/spec/spec_helper.rb
|
||||
${GEM_LIBDIR}/spec/system_command_spec.rb
|
||||
${GEM_LIBDIR}/spec/verifiers/json_verifier_spec.rb
|
||||
${GEM_HOME}/specifications/${GEM_NAME}.gemspec
|
6
devel/ruby-approvaltests/distinfo
Normal file
6
devel/ruby-approvaltests/distinfo
Normal file
|
@ -0,0 +1,6 @@
|
|||
$NetBSD: distinfo,v 1.1 2021/06/07 19:55:27 schmonz Exp $
|
||||
|
||||
SHA1 (approvals-0.0.25.gem) = f05c4f0063ddca04a42ce99809f1386d0390cffc
|
||||
RMD160 (approvals-0.0.25.gem) = d3ee14441cd74888fc52a7ce48d2c9c8d658aafa
|
||||
SHA512 (approvals-0.0.25.gem) = 53c989bb91588de5fe656133291844a4f2614fbd9c8c05aff96b3dc19fb2ef3e6f31eb0fa62b05199e7ebeb3995dd507c02ac6e9d22d17b998977b1112e4fef8
|
||||
Size (approvals-0.0.25.gem) = 35840 bytes
|
Loading…
Reference in a new issue