Sha256: 53bae3224a0856644ca4d6afda6aeaa04dbbc15488e3e9caa48d9206430e49bd

Contents?: true

Size: 227 Bytes

Versions: 5

Compression:

Stored size: 227 Bytes

Contents

  def test_destroy
    <%= instance_name %> = <%= class_name %>.first
    delete :destroy, id: <%= instance_name %>
    assert_redirected_to <%= items_url %>
    assert !<%= class_name %>.exists?(<%= instance_name %>.id)
  end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
zoo-generators-0.1.5 lib/generators/zoo/scaffold/templates/tests/testunit/actions/destroy.rb
zoo-generators-0.1.4 lib/generators/zoo/scaffold/templates/tests/testunit/actions/destroy.rb
zoo-generators-0.1.3 lib/generators/zoo/scaffold/templates/tests/testunit/actions/destroy.rb
zoo-generators-0.1.2 lib/generators/zoo/scaffold/templates/tests/testunit/actions/destroy.rb
zoo-generators-0.1.1 lib/generators/zoo/scaffold/templates/tests/testunit/actions/destroy.rb