1 require "application_system_test_case"
3 class AccountPdDeclarationTest < ApplicationSystemTestCase
5 @user = create(:user, :display_name => "test user")
9 test "show checkbox if no declaration was made" do
10 visit account_pd_declaration_path
12 within_content_body do
13 assert_unchecked_field "I consider my contributions to be in the Public Domain"
14 assert_button "Confirm"
18 test "show disabled checkbox if declaration was made" do
19 @user.update(:consider_pd => true)
21 visit account_pd_declaration_path
23 within_content_body do
24 assert_checked_field "I consider my contributions to be in the Public Domain", :disabled => true
25 assert_button "Confirm", :disabled => true