How do I pass form values from POST controller specs?

Luis Lavena
Sat, 19 Jan 2008 13:56:28 -0000

On Jan 18, 2008 9:55 AM, aslak hellesoy <aslak.hellesoy at gmail.com>
wrote:
> [...]
>
>
> Now I''m running into a new problem. I''m using a frozen
Merb core and
> ActiveRecord, so I need to use merb_activerecord. I cannot install
> merb_activerecord as a gem, because the gem wants Merb 0.5.2 which is
> not the core I want. So I don''t have any global merb related gems
> installed. I''ve tried this:
>
> piston import http://svn.devjavu.com/merb/plugins/merb_activerecord
> gems/gems/merb_activerecord
> (I guess I need the trunk of this since I have the trunk of core)
>
> However, Merb is unable to find merb_activerecord:

Merb is expecting you have a valid gems installation inside gem/ directory.

Checkout just merb_activerecord subtree into gems/gems will not work,
since you need the merb_activerecord-version.gemspec inside
gem/specifications too.

What you can do is (with rubygems 1.0.1):

cd into your merb app folder.

gem fetch merb_activerecord
gem install merb_activerecord-0.5.gem -i gems

That will be problematic, since all the dependencies of that gem will
be installed there, and also merb dependencies too.

you will end with something like this inside gems/gems:

abstract-1.0.0
activesupport-2.0.2
cgi_multipart_eof_fix-2.5.0
erubis-2.4.1
gem_plugin-0.2.3
hoe-1.4.0
json_pure-1.1.2
merb-0.5.2
merb_activerecord-0.5
mime-types-1.15
mongrel-1.1.3-x86-mswin32
ParseTree-2.1.1-x86-mswin32
rake-0.8.1
rubigen-1.1.1
ruby2ruby-1.1.8
rubyforge-0.4.4
RubyInline-3.6.6

You can remove the merb-0.5.2 gems and also all the others, I think is
a GEM_PATH / GEM_HOME issue and not a problem of merb directly.

Please ignore the ''x86-mswin32'' gems since I''m on
Windows :-)

> rake specs # from my app root
> rake aborted!
> no such file to load -- merb_activerecord
>
> When I decide to use Merb core"edge", what''s the best
way to also get
> Merb ActiveRecord "edge"?
>

svn co http://svn.devjavu.com/merb/plugins/merb_activerecord merb_activerecord
cd merb_activerecord
rake package (to generate the .gem file)

Use as previously indicated.

HTH,
--
Luis Lavena
Multimedia systems
-
A common mistake that people make when trying to design
something completely foolproof is to underestimate
the ingenuity of complete fools.
Douglas Adams