Allow disabling AI assistant (#146)

* Test disabling AI assistant

* Leave "Maybe" out of it

* It's "sure" now
This commit is contained in:
Juan José Mata
2025-10-22 22:11:01 +02:00
committed by GitHub
parent 4cd737b5d9
commit e7e85748e4
4 changed files with 38 additions and 1 deletions

View File

@@ -0,0 +1,19 @@
require "application_system_test_case"
class Settings::AiPromptsTest < ApplicationSystemTestCase
setup do
@user = users(:family_admin)
@user.update!(ai_enabled: true)
login_as @user
end
test "user can disable ai assistant" do
visit settings_ai_prompts_path
click_button "Disable AI Assistant"
assert_current_path settings_ai_prompts_path
@user.reload
assert_not @user.ai_enabled?
end
end