Integration testing ..

H

Hemant Bhargava

Hi Champs,

In urgent need of you people .. :) Actually i am writing integration
tests for my application. I am checking out that -
- Are all the pages accessible to admin by creating a session ?
- The same way are the same pages are not accessible to normal user?

I have defined a module and running a simple get request to it as like

def test_access_pages_admin
get "employees"
assert_response :success
assert_template "employees/login_page"
end


But i am getting error over here. Error is-
"ActiveRecord::StatementInvalid: Mysql::Error: You have an error in your
SQL syntax; check the manual that corresponds to your MySQL server
version for the right syntax to use near 'RELEASE SAVEPOINT
active_record_1' at line 1: RELEASE SAVEPOINT active_record_1"

Can someone light me the right direction. Waiting for every possible
answer.
 
R

Richard Conroy

[Note: parts of this message were removed to make it a legal post.]

On Tue, Jan 12, 2010 at 10:13 AM, Hemant Bhargava <
Hi Champs,

In urgent need of you people .. :) Actually i am writing integration
tests for my application. I am checking out that -
- Are all the pages accessible to admin by creating a session ?
- The same way are the same pages are not accessible to normal user?
I am assuming you are using Rails? You might wish to direct your query on
the Rails list.
In addition you will probably need to supply more illustrative code
snippets, in particular
of your configuration and environment sections.
 
B

Brian Candler

Hemant said:
I have defined a module and running a simple get request to it as like

def test_access_pages_admin
get "employees"
assert_response :success
assert_template "employees/login_page"
end

That looks like Rails code. Please ask your question on a Rails mailing
list. Rails is not Ruby; it just happens to be written *in* Ruby.
 
H

Hemant Bhargava

Ohh ..
M sorry .. :)

Brian said:
That looks like Rails code. Please ask your question on a Rails mailing
list. Rails is not Ruby; it just happens to be written *in* Ruby.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,578
Members
45,052
Latest member
LucyCarper

Latest Threads

Top