diff options
author | seb <seb@pkgsrc.org> | 2008-04-07 00:32:28 +0000 |
---|---|---|
committer | seb <seb@pkgsrc.org> | 2008-04-07 00:32:28 +0000 |
commit | 2fa7db71a26a1612fca318b0997cbce0769f1863 (patch) | |
tree | 57ff8d3b2bd56acda320d5cea7ed8c9cc71a7bd0 /devel | |
parent | 9bcc089d4f645edfa661e99b3ff309a84bdac347 (diff) | |
download | pkgsrc-2fa7db71a26a1612fca318b0997cbce0769f1863.tar.gz |
Initial import of ruby-mocha as version 0.5.6 into the NetBSD
Packages Collection.
Mocha is a Ruby library for mocking and stubbing using a syntax
like that of JMock, and SchMock. Most commonly Mocha is used in
conjunction with Test::Unit, but it can be used in other contexts.
One of its main advantages is that it allows you to mock and stub
methods on real (non-mock) classes and instances. You can for
example stub ActiveRecord instance methods like create, save,
destroy and even class methods like find to avoid hitting the
database in unit tests.
Mocha provides a unified, simple and readable syntax for both
traditional mocking and for mocking with real objects.
Diffstat (limited to 'devel')
-rw-r--r-- | devel/ruby-mocha/DESCR | 12 | ||||
-rw-r--r-- | devel/ruby-mocha/Makefile | 16 | ||||
-rw-r--r-- | devel/ruby-mocha/PLIST | 136 | ||||
-rw-r--r-- | devel/ruby-mocha/distinfo | 5 | ||||
-rw-r--r-- | devel/ruby-mocha/patch-aa | 15 |
5 files changed, 184 insertions, 0 deletions
diff --git a/devel/ruby-mocha/DESCR b/devel/ruby-mocha/DESCR new file mode 100644 index 00000000000..7256763a24c --- /dev/null +++ b/devel/ruby-mocha/DESCR @@ -0,0 +1,12 @@ +Mocha is a Ruby library for mocking and stubbing using a syntax +like that of JMock, and SchMock. Most commonly Mocha is used in +conjunction with Test::Unit, but it can be used in other contexts. + +One of its main advantages is that it allows you to mock and stub +methods on real (non-mock) classes and instances. You can for +example stub ActiveRecord instance methods like create, save, +destroy and even class methods like find to avoid hitting the +database in unit tests. + +Mocha provides a unified, simple and readable syntax for both +traditional mocking and for mocking with real objects. diff --git a/devel/ruby-mocha/Makefile b/devel/ruby-mocha/Makefile new file mode 100644 index 00000000000..086af96b94f --- /dev/null +++ b/devel/ruby-mocha/Makefile @@ -0,0 +1,16 @@ +# $NetBSD: Makefile,v 1.1.1.1 2008/04/07 00:32:28 seb Exp $ + +DISTNAME= mocha-0.5.6 +PKGNAME= ${RUBYGEM_PKGPREFIX}-${DISTNAME} +#PKGREVISION= 1 +CATEGORIES= devel + +MAINTAINER= pkgsrc-users@NetBSD.org +HOMEPAGE= http://mocha.rubyforge.org/ +COMMENT= Ruby library for mocking and stubbing + +#pre-build: +# rm -f ${WRKSRC}/*.orig + +.include "../../misc/rubygems/rubygem.mk" +.include "../../mk/bsd.pkg.mk" diff --git a/devel/ruby-mocha/PLIST b/devel/ruby-mocha/PLIST new file mode 100644 index 00000000000..066e3741363 --- /dev/null +++ b/devel/ruby-mocha/PLIST @@ -0,0 +1,136 @@ +@comment $NetBSD: PLIST,v 1.1.1.1 2008/04/07 00:32:28 seb Exp $ +${GEM_HOME}/cache/mocha-${PKGVERSION}.gem +${GEM_LIBDIR}/COPYING +${GEM_LIBDIR}/MIT-LICENSE +${GEM_LIBDIR}/README +${GEM_LIBDIR}/RELEASE +${GEM_LIBDIR}/Rakefile +${GEM_LIBDIR}/examples/misc.rb +${GEM_LIBDIR}/examples/mocha.rb +${GEM_LIBDIR}/examples/stubba.rb +${GEM_LIBDIR}/lib/mocha.rb +${GEM_LIBDIR}/lib/mocha/any_instance_method.rb +${GEM_LIBDIR}/lib/mocha/auto_verify.rb +${GEM_LIBDIR}/lib/mocha/central.rb +${GEM_LIBDIR}/lib/mocha/class_method.rb +${GEM_LIBDIR}/lib/mocha/deprecation.rb +${GEM_LIBDIR}/lib/mocha/exception_raiser.rb +${GEM_LIBDIR}/lib/mocha/expectation.rb +${GEM_LIBDIR}/lib/mocha/expectation_error.rb +${GEM_LIBDIR}/lib/mocha/expectation_list.rb +${GEM_LIBDIR}/lib/mocha/infinite_range.rb +${GEM_LIBDIR}/lib/mocha/inspect.rb +${GEM_LIBDIR}/lib/mocha/instance_method.rb +${GEM_LIBDIR}/lib/mocha/is_a.rb +${GEM_LIBDIR}/lib/mocha/metaclass.rb +${GEM_LIBDIR}/lib/mocha/method_matcher.rb +${GEM_LIBDIR}/lib/mocha/missing_expectation.rb +${GEM_LIBDIR}/lib/mocha/mock.rb +${GEM_LIBDIR}/lib/mocha/multiple_yields.rb +${GEM_LIBDIR}/lib/mocha/no_yields.rb +${GEM_LIBDIR}/lib/mocha/object.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/all_of.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/any_of.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/any_parameters.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/anything.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/base.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/equals.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/has_entries.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/has_entry.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/has_key.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/has_value.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/includes.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/instance_of.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/is_a.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/kind_of.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/not.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/object.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/optionally.rb +${GEM_LIBDIR}/lib/mocha/parameter_matchers/regexp_matches.rb +${GEM_LIBDIR}/lib/mocha/parameters_matcher.rb +${GEM_LIBDIR}/lib/mocha/pretty_parameters.rb +${GEM_LIBDIR}/lib/mocha/return_values.rb +${GEM_LIBDIR}/lib/mocha/sequence.rb +${GEM_LIBDIR}/lib/mocha/setup_and_teardown.rb +${GEM_LIBDIR}/lib/mocha/single_return_value.rb +${GEM_LIBDIR}/lib/mocha/single_yield.rb +${GEM_LIBDIR}/lib/mocha/standalone.rb +${GEM_LIBDIR}/lib/mocha/stub.rb +${GEM_LIBDIR}/lib/mocha/test_case_adapter.rb +${GEM_LIBDIR}/lib/mocha/yield_parameters.rb +${GEM_LIBDIR}/lib/mocha_standalone.rb +${GEM_LIBDIR}/lib/stubba.rb +${GEM_LIBDIR}/test/acceptance/expected_invocation_count_acceptance_test.rb +${GEM_LIBDIR}/test/acceptance/mocha_acceptance_test.rb +${GEM_LIBDIR}/test/acceptance/mock_with_initializer_block_acceptance_test.rb +${GEM_LIBDIR}/test/acceptance/mocked_methods_dispatch_acceptance_test.rb +${GEM_LIBDIR}/test/acceptance/optional_parameters_acceptance_test.rb +${GEM_LIBDIR}/test/acceptance/parameter_matcher_acceptance_test.rb +${GEM_LIBDIR}/test/acceptance/partial_mocks_acceptance_test.rb +${GEM_LIBDIR}/test/acceptance/sequence_acceptance_test.rb +${GEM_LIBDIR}/test/acceptance/standalone_acceptance_test.rb +${GEM_LIBDIR}/test/acceptance/stubba_acceptance_test.rb +${GEM_LIBDIR}/test/active_record_test_case.rb +${GEM_LIBDIR}/test/deprecation_disabler.rb +${GEM_LIBDIR}/test/execution_point.rb +${GEM_LIBDIR}/test/integration/mocha_test_result_integration_test.rb +${GEM_LIBDIR}/test/integration/stubba_integration_test.rb +${GEM_LIBDIR}/test/integration/stubba_test_result_integration_test.rb +${GEM_LIBDIR}/test/method_definer.rb +${GEM_LIBDIR}/test/test_helper.rb +${GEM_LIBDIR}/test/test_runner.rb +${GEM_LIBDIR}/test/unit/any_instance_method_test.rb +${GEM_LIBDIR}/test/unit/array_inspect_test.rb +${GEM_LIBDIR}/test/unit/auto_verify_test.rb +${GEM_LIBDIR}/test/unit/central_test.rb +${GEM_LIBDIR}/test/unit/class_method_test.rb +${GEM_LIBDIR}/test/unit/date_time_inspect_test.rb +${GEM_LIBDIR}/test/unit/expectation_error_test.rb +${GEM_LIBDIR}/test/unit/expectation_list_test.rb +${GEM_LIBDIR}/test/unit/expectation_raiser_test.rb +${GEM_LIBDIR}/test/unit/expectation_test.rb +${GEM_LIBDIR}/test/unit/hash_inspect_test.rb +${GEM_LIBDIR}/test/unit/infinite_range_test.rb +${GEM_LIBDIR}/test/unit/metaclass_test.rb +${GEM_LIBDIR}/test/unit/method_matcher_test.rb +${GEM_LIBDIR}/test/unit/missing_expectation_test.rb +${GEM_LIBDIR}/test/unit/mock_test.rb +${GEM_LIBDIR}/test/unit/multiple_yields_test.rb +${GEM_LIBDIR}/test/unit/no_yield_test.rb +${GEM_LIBDIR}/test/unit/object_inspect_test.rb +${GEM_LIBDIR}/test/unit/object_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/all_of_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/any_of_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/anything_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/has_entries_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/has_entry_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/has_key_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/has_value_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/includes_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/instance_of_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/is_a_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/kind_of_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/not_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/regexp_matches_test.rb +${GEM_LIBDIR}/test/unit/parameter_matchers/stub_matcher.rb +${GEM_LIBDIR}/test/unit/parameters_matcher_test.rb +${GEM_LIBDIR}/test/unit/return_values_test.rb +${GEM_LIBDIR}/test/unit/sequence_test.rb +${GEM_LIBDIR}/test/unit/setup_and_teardown_test.rb +${GEM_LIBDIR}/test/unit/single_return_value_test.rb +${GEM_LIBDIR}/test/unit/single_yield_test.rb +${GEM_LIBDIR}/test/unit/string_inspect_test.rb +${GEM_LIBDIR}/test/unit/stub_test.rb +${GEM_LIBDIR}/test/unit/yield_parameters_test.rb +${GEM_HOME}/specifications/mocha-${PKGVERSION}.gemspec +@dirrm ${GEM_LIBDIR}/test/unit/parameter_matchers +@dirrm ${GEM_LIBDIR}/test/unit +@dirrm ${GEM_LIBDIR}/test/integration +@dirrm ${GEM_LIBDIR}/test/acceptance +@dirrm ${GEM_LIBDIR}/test +@dirrm ${GEM_LIBDIR}/lib/mocha/parameter_matchers +@dirrm ${GEM_LIBDIR}/lib/mocha +@dirrm ${GEM_LIBDIR}/lib +@dirrm ${GEM_LIBDIR}/examples +@dirrm ${GEM_LIBDIR} diff --git a/devel/ruby-mocha/distinfo b/devel/ruby-mocha/distinfo new file mode 100644 index 00000000000..bd3d6ef9059 --- /dev/null +++ b/devel/ruby-mocha/distinfo @@ -0,0 +1,5 @@ +$NetBSD: distinfo,v 1.1.1.1 2008/04/07 00:32:28 seb Exp $ + +SHA1 (mocha-0.5.6.gem) = 345e950cb57d393437c7ad67cd3c09a3142a24fd +RMD160 (mocha-0.5.6.gem) = 301e95d46c363dc758a521ac109dbe43b07f21a6 +Size (mocha-0.5.6.gem) = 42498 bytes diff --git a/devel/ruby-mocha/patch-aa b/devel/ruby-mocha/patch-aa new file mode 100644 index 00000000000..7aee00ac671 --- /dev/null +++ b/devel/ruby-mocha/patch-aa @@ -0,0 +1,15 @@ +$NetBSD: patch-aa,v 1.1.1.1 2008/04/07 00:32:28 seb Exp $ + +Drop the dependency on the gem 'rake' as Rake is not installed as a gem. + +--- Rakefile.orig 2008-03-25 21:15:48.000000000 +0000 ++++ Rakefile +@@ -110,7 +110,7 @@ specification = Gem::Specification.new d + s.rdoc_options << '--title' << 'Mocha' << '--main' << 'README' << '--line-numbers' + + s.autorequire = 'mocha' +- s.add_dependency('rake') ++# s.add_dependency('rake') + s.files = FileList['{lib,test,examples}/**/*.rb', '[A-Z]*'].exclude('TODO').to_a + end + |