require 'test_helper'

class GgradesControllerTest < ActionController::TestCase
  test "should get index" do
    get :index
    assert_response :success
    assert_not_nil assigns(:ggrades)
  end

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

  test "should create ggrade" do
    assert_difference('Ggrade.count') do
      post :create, :ggrade => { }
    end

    assert_redirected_to ggrade_path(assigns(:ggrade))
  end

  test "should show ggrade" do
    get :show, :id => ggrades(:one).to_param
    assert_response :success
  end

  test "should get edit" do
    get :edit, :id => ggrades(:one).to_param
    assert_response :success
  end

  test "should update ggrade" do
    put :update, :id => ggrades(:one).to_param, :ggrade => { }
    assert_redirected_to ggrade_path(assigns(:ggrade))
  end

  test "should destroy ggrade" do
    assert_difference('Ggrade.count', -1) do
      delete :destroy, :id => ggrades(:one).to_param
    end

    assert_redirected_to ggrades_path
  end
end
