में एक अलग नियंत्रक को पोस्ट करें, मैं परीक्षण स्क्रिप्ट वर्तमान में किस बिंदु पर इंगित कर रहा हूं उससे अलग नियंत्रक को कैसे पोस्ट करूं?एक आरएसपीईसी परीक्षण
उदाहरण: user_controller_spec.rb में
it "should just post to users" do
post :create, @params # this goes to the users controller
end
मैं की तरह कुछ करना चाहता हूँ:
it "should post to user and people to do some integration testing" do
post :create, @params # this goes to the users controller still
post 'people', :create, @params # this goes to the people controller
end
पुनश्च: मैं सेटअप ककड़ी नहीं करना चाहती
भयानक! मेरे लिए बहुत अच्छा काम करता है। – Tilo
मैं यह जांचना चाहता था कि यह कौन सा नियंत्रक मार रहा है, इससे थोड़ा सा मदद मिली। –