[Rails] simple captcha instllation problems

2010-02-03 Thread vihrao
I am running XP. Downloaded simple captcha from expressica, unzipped into vendor/plugin. Ran rake simple_captcha:setup. Gives me error: rake aborted! don't know how to build task 'simple captcha:setup_old' I checked rails version by gem list rails Gives me rails 2.3.5, 1,2,2 can someone tell me

[Rails] assert_equal Test - how to test updates

2010-02-02 Thread vihrao
I am testing an update via assert_equal and it does not seem to work. I have this fixture: bob1: id: 101 login: bob glogin: b...@mcbob.com session_token: 77a38 Here is my test method: class Guser ActiveRecord::Base def self.update_token(glogin, login, stoken) u=find(:first,

Re: [Rails] assert_equal Test - how to test updates

2010-02-02 Thread vihrao
I meant it does not update the value from '77a38' to '77a138' vihrao wrote: I am testing an update via assert_equal and it does not seem to work. I have this fixture: bob1: id: 101 login: bob glogin: b...@mcbob.com session_token: 77a38 Here is my test method: class

Re: [Rails] assert_equal Test - how to test updates

2010-02-02 Thread vihrao
On Feb 2, 5:55 pm, vihrao vih...@gmail.com wrote: Then I run it again by changing the method argument like this to update the sesison token  assert_equal �...@bob1, Guser.update_token(b...@mcbob.com, bob, 77a138) It still gives a success message: 1 tests, 1 assertions, 0 failures, 0

Re: [Rails] assert_equal Test - how to test updates

2010-02-02 Thread vihrao
assert_equal uses the == method to compare the two objects, and == on activerecord doesn't compare attributes: it only compares the id of the object (ie do the compared objects represent the same row in the database) Fred -- That is why I had this issue. I had two fixtures users.yml and

Re: [Rails] Action path - syntax error, unexpected tIDENTIFIER, expecting ')'

2010-02-01 Thread vihrao
Rob Biedenharn-2 wrote: On Jan 31, 2010, at 3:50 PM, vihrao wrote: I tried %= link_to 'Login', login_user_path(user) % it did not work I tried: %= link_to 'Login', :controller = 'user', :action = 'login' % that worked. So I still don't get how the REST Path is defined and can

Re: [Rails] Action path - syntax error, unexpected tIDENTIFIER, expecting ')'

2010-02-01 Thread vihrao
Thank you. I was confused between named routes and RESTful routes Rob Biedenharn-2 wrote: On Feb 1, 2010, at 12:19 PM, vihrao wrote: Rob Biedenharn-2 wrote: On Jan 31, 2010, at 3:50 PM, vihrao wrote: I tried %= link_to 'Login', login_user_path(user) % it did not work I tried

[Rails] Action path - syntax error, unexpected tIDENTIFIER, expecting ')'

2010-01-31 Thread vihrao
I have a user controller with login as action. When I access the index.html.erb file via application.layout file. I get a error on the login link on the index.html.erb page. I think I am having dfifficulty in setting up path to an action or even understanding how to set REST path properly. Can

Re: [Rails] Action path - syntax error, unexpected tIDENTIFIER, expecting ')'

2010-01-31 Thread vihrao
I tried %= link_to 'Login', login_user_path(user) % it did not work I tried: %= link_to 'Login', :controller = 'user', :action = 'login' % that worked. So I still don't get how the REST Path is defined and can be used? Rob Biedenharn-2 wrote: On Jan 31, 2010, at 2:40 PM, vihrao wrote: I

[Rails] how to build a welcome page?

2010-01-24 Thread vihrao
I am describing what I am trying to accomplish: I want to create a main welcome page. So I ran script/generate admin/welcome. This created welcome controller Then I wanted to attach this welcome controller to the main application.html.erb In the application.html.erb file I want to show a ‘login’

[Rails] XML and XML schema support

2010-01-04 Thread vihrao
I want to convert web page in to a XML document and validate it with a XML Schema.Can I do this with Ruby on Rails framework. Please let me know. -- You received this message because you are subscribed to the Google Groups Ruby on Rails: Talk group. To post to this group, send email to