Let user remove nostr pubkey from account
This commit is contained in:
@@ -19,4 +19,22 @@ RSpec.describe 'Experimental Settings', type: :feature do
|
||||
# worth it for now
|
||||
# end
|
||||
end
|
||||
|
||||
context "With pubkey configured" do
|
||||
before do
|
||||
user.update! nostr_pubkey: "07e188a1ff87ce171d517b8ed2bb7a31b1d3453a0db3b15379ec07b724d232f3"
|
||||
end
|
||||
|
||||
scenario 'Remove nostr pubkey from account' do
|
||||
visit settings_experiments_path
|
||||
expect(page).to have_field("nostr_public_key",
|
||||
with: "07e188a1ff87ce171d517b8ed2bb7a31b1d3453a0db3b15379ec07b724d232f3",
|
||||
disabled: true)
|
||||
|
||||
click_link "Remove"
|
||||
expect(page).to_not have_field("nostr_public_key")
|
||||
expect(page).to have_content("verify your public key")
|
||||
expect(user.reload.nostr_pubkey).to be_nil
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user