- # for now just check that we are back in Users -> List page
- assert page.has_text? 'zzzzz-tpzed-d9tiejq69daie8f'
- end
-
- #@headless
- test "unsetup active user" do
- Capybara.current_driver = Capybara.javascript_driver
- #Capybara.current_driver = :selenium
-
- visit page_with_token('admin_trustedclient')
-
- click_link 'Users'
-
- assert page.has_link? 'zzzzz-tpzed-xurymjxw79nv3jz'
-
- # click on active user
- click_link 'zzzzz-tpzed-xurymjxw79nv3jz'
-
- # Verify that is_active is set
- click_link 'Attributes'
- assert page.has_text? 'modified_by_user_uuid'
- page.within(:xpath, '//a[@data-name="is_active"]') do
- assert_equal "true", text, "Expected user's is_active to be true"
- end
-
- # go to Admin tab
- click_link 'Admin'
- assert page.has_text? 'As an admin, you can deactivate and reset this user'
-
- # Click on Deactivate button
- click_button 'Deactivate Active User'
-
- # Click Ok in the confirm dialog
-=begin
-#use with selenium
- page.driver.browser.switch_to.alert.accept