mirror of
https://github.com/mastodon/mastodon.git
synced 2026-03-21 18:05:23 -05:00
13 lines
337 B
Ruby
13 lines
337 B
Ruby
# frozen_string_literal: true
|
|
|
|
require 'rails_helper'
|
|
|
|
RSpec.describe PreviewCard do
|
|
describe 'Validations' do
|
|
describe 'url' do
|
|
it { is_expected.to allow_values('http://example.host/path', 'https://example.host/path').for(:url) }
|
|
it { is_expected.to_not allow_value('javascript:alert()').for(:url) }
|
|
end
|
|
end
|
|
end
|