Sha256: 5a29db5b12e178f86226a73052a6ad85eb4e3c9e3e869c8c23ccb8725c1ad89b
Contents?: true
Size: 1.1 KB
Versions: 5
Compression:
Stored size: 1.1 KB
Contents
require 'test_helper' class OrganismsControllerTest < ActionController::TestCase setup do @organism = organisms(:one) end test "should get index" do get :index assert_response :success assert_not_nil assigns(:organisms) end test "should get new" do get :new assert_response :success end test "should create organism" do assert_difference('Organism.count') do post :create, organism: { status: @organism.status, title: @organism.title } end assert_redirected_to organism_path(assigns(:organism)) end test "should show organism" do get :show, id: @organism assert_response :success end test "should get edit" do get :edit, id: @organism assert_response :success end test "should update organism" do put :update, id: @organism, organism: { status: @organism.status, title: @organism.title } assert_redirected_to organism_path(assigns(:organism)) end test "should destroy organism" do assert_difference('Organism.count', -1) do delete :destroy, id: @organism end assert_redirected_to organisms_path end end
Version data entries
5 entries across 5 versions & 1 rubygems