rspec test, how to get the id in my case?
I have a rsepc test for my controller, in my test, I have the following code snippet:

    ...
    params= {SOME PARAMETERS}
    post :create, params

the above code test the **create** method in my controller, the **create** method create a instance object and save it into database. 

Now the problem is how can I get the **id** of the created instance object in database? 

It seems (I am not sure) I need to query the test database for this object, how to query?
(PS: I know there is **Factory** can be used to create object instance, BUT this is a test for controller, use Factory will loose the purpose of testing controller's create method. So, please do not advice me to use **Factory**)

I would like to know how to get the id of my created object instance based on my code? Thank you:)  
rspec test, how to get the id in my case?
===

I have a rsepc test for my controller, in my test, I have the following code snippet:

    ...
    params= {SOME PARAMETERS}
    post :create, params

the above code test the **create** method in my controller, the **create** method create a instance object and save it into database. 

Now the problem is how can I get the **id** of the created instance object in database? 

It seems (I am not sure) I need to query the test database for this object, how to query?
(PS: I know there is **Factory** can be used to create object instance, BUT this is a test for controller, use Factory will loose the purpose of testing controller's create method. So, please do not advice me to use **Factory**)

I would like to know how to get the id of my created object instance based on my code? Thank you:)  