summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2015-08-08 13:49:04 -0700
committerRobin H. Johnson <robbat2@gentoo.org>2015-08-08 17:38:18 -0700
commit56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch)
tree3f91093cdb475e565ae857f1c5a7fd339e2d781e /dev-ruby/mongoid
downloadgentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2
gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip
proj/gentoo: Initial commit
This commit represents a new era for Gentoo: Storing the gentoo-x86 tree in Git, as converted from CVS. This commit is the start of the NEW history. Any historical data is intended to be grafted onto this point. Creation process: 1. Take final CVS checkout snapshot 2. Remove ALL ChangeLog* files 3. Transform all Manifests to thin 4. Remove empty Manifests 5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$ 5.1. Do not touch files with -kb/-ko keyword flags. Signed-off-by: Robin H. Johnson <robbat2@gentoo.org> X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'dev-ruby/mongoid')
-rw-r--r--dev-ruby/mongoid/Manifest1
-rw-r--r--dev-ruby/mongoid/metadata.xml8
-rw-r--r--dev-ruby/mongoid/mongoid-2.8.1.ebuild81
3 files changed, 90 insertions, 0 deletions
diff --git a/dev-ruby/mongoid/Manifest b/dev-ruby/mongoid/Manifest
new file mode 100644
index 000000000000..85dc7c5674bb
--- /dev/null
+++ b/dev-ruby/mongoid/Manifest
@@ -0,0 +1 @@
+DIST mongoid-2.8.1.tar.gz 367336 SHA256 76289084e680fe4ba476112eadda9dac0212a28e169023e84788db8a56494305 SHA512 cdd7e92722a5451c8d9ef0a21b7176446f9d6f41f42f62e0f91006feb6217a4a5c3bf2b193ee57d196aef2a61dc13b50cd76c35da295140abc4a7136d02eda81 WHIRLPOOL b4bc238ef853b1bc8dd42169f1075bd75f6f10fbe02c41aedf93901cb66d79527d6815c8934da2738f8f82ff24081995f6487fc4959888b25014f25509110dd6
diff --git a/dev-ruby/mongoid/metadata.xml b/dev-ruby/mongoid/metadata.xml
new file mode 100644
index 000000000000..12cd7d2dfb7f
--- /dev/null
+++ b/dev-ruby/mongoid/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>ruby</herd>
+ <upstream>
+ <remote-id type="github">mongoid/mongoid</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-ruby/mongoid/mongoid-2.8.1.ebuild b/dev-ruby/mongoid/mongoid-2.8.1.ebuild
new file mode 100644
index 000000000000..32e97221ed82
--- /dev/null
+++ b/dev-ruby/mongoid/mongoid-2.8.1.ebuild
@@ -0,0 +1,81 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+USE_RUBY="ruby20 ruby21"
+
+RUBY_FAKEGEM_RECIPE_DOC="rdoc"
+# functional testing crashes Ruby from within Portage, but works
+# outside of it, needs to be investigated thoroughly, but at least
+# unit testing works.
+RUBY_FAKEGEM_RECIPE_TEST="rspec"
+
+RUBY_FAKEGEM_EXTRADOC="README.md CHANGELOG.md"
+
+RUBY_FAKEGEM_GEMSPEC="${PN}.gemspec"
+
+GITHUB_USER="${PN}"
+GITHUB_PROJECT="${PN}"
+
+inherit ruby-fakegem
+
+DESCRIPTION="ODM (Object Document Mapper) Framework for MongoDB"
+HOMEPAGE="http://two.mongoid.org/"
+SRC_URI="https://github.com/${GITHUB_USER}/${GITHUB_PROJECT}/archive/v${PV}.tar.gz -> ${GITHUB_PROJECT}-${PV}.tar.gz"
+LICENSE="MIT"
+
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="test"
+
+ruby_add_rdepend "
+ >=dev-ruby/activemodel-3.1 =dev-ruby/activemodel-3*
+ >=dev-ruby/mongo-1.9:0
+ >=dev-ruby/tzinfo-0.3.22:0
+"
+
+ruby_add_bdepend "
+ test? (
+ dev-ruby/bundler
+ dev-ruby/ammeter
+ dev-ruby/mocha:0.11
+ dev-ruby/rdoc
+ dev-ruby/rspec
+ dev-util/watchr
+ )"
+
+DEPEND+=" test? ( dev-db/mongodb )"
+
+all_ruby_prepare() {
+ # Remove unsupported development dependencies and fix versions.
+ sed -i -e '/\(guard-rspec\|rb-fsevent\)/ s:^:#:' \
+ -e '/mocha/ s/= 0.11/~> 0.11.0/' mongoid.gemspec || die
+
+ # Avoid specs tied to localhost
+ rm spec/functional/mongoid/config/{database,replset_database}_spec.rb || die
+
+ # Avoid some failing specs that should be investigated later
+ sed -i -e '/sets the capped size/,/end/ s:^:#:' spec/functional/mongoid/collection_spec.rb || die
+ sed -i -e '/.from_hash/,/^ end/ s:^:#:' spec/functional/mongoid/config_spec.rb || die
+ rm spec/functional/mongoid/persistence_spec.rb || die
+}
+
+each_ruby_test() {
+ mkdir "${T}/mongodb_$(basename $RUBY)"
+ mongod --port 27017 --dbpath "${T}/mongodb_$(basename $RUBY)" \
+ --noprealloc --noauth --nohttpinterface --nounixsocket --nojournal \
+ --bind_ip 127.255.255.254 &
+ mongod_pid=$!
+ failed=0
+
+ sleep 2
+
+ export MONGOID_SPEC_HOST="127.255.255.254"
+ export MONGOID_SPEC_PORT="27017"
+
+ ${RUBY} -S bundle exec rspec-2 --format progress spec || failed=1
+ kill "${mongod_pid}"
+
+ [[ "${failed}" == "1" ]] && die "tests failed"
+}