Sha256: 8f5813490d3a481df51e2057846fc7a6d5bee5f6580e08a0a34589c1a0334136

Contents?: true

Size: 1.09 KB

Versions: 7

Compression:

Stored size: 1.09 KB

Contents

require 'test_helper'

class DirectoriesControllerTest < ActionDispatch::IntegrationTest
  setup do
    @directory = directories(:one)
  end

  test "should get index" do
    get directories_url
    assert_response :success
  end

  test "should get new" do
    get new_directory_url
    assert_response :success
  end

  test "should create directory" do
    assert_difference('Directory.count') do
      post directories_url, params: { directory: { path: @directory.path } }
    end

    assert_redirected_to directory_url(Directory.last)
  end

  test "should show directory" do
    get directory_url(@directory)
    assert_response :success
  end

  test "should get edit" do
    get edit_directory_url(@directory)
    assert_response :success
  end

  test "should update directory" do
    patch directory_url(@directory), params: { directory: { path: @directory.path } }
    assert_redirected_to directory_url(@directory)
  end

  test "should destroy directory" do
    assert_difference('Directory.count', -1) do
      delete directory_url(@directory)
    end

    assert_redirected_to directories_url
  end
end

Version data entries

7 entries across 7 versions & 2 rubygems

Version Path
jester-data-8.0.0 test/controllers/directories_controller_test.rb
ezii-os-5.2.1 test/controllers/directories_controller_test.rb
ezii-os-2.0.1 test/controllers/directories_controller_test.rb
ezii-os-1.1.0 test/controllers/directories_controller_test.rb
ezii-os-1.0.0 test/controllers/directories_controller_test.rb
ezii-os-0.0.0.1.0 test/controllers/directories_controller_test.rb
ezii-os-0.0.0.0.1 test/controllers/directories_controller_test.rb