File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -258,30 +258,6 @@ class LegacyEditionWorkflowTest < LegacyJavascriptIntegrationTest
258258 assert_equal "Blah blah fact check message" , resent_fact_check_email . body . to_s
259259 end
260260
261- test "sending a fact check email to a non-permitted address will return an error" do
262- raises_exception = lambda { |_request , _params |
263- response = Minitest ::Mock . new
264- response . expect :code , 400
265- response . expect :body , "Can't send to this recipient using a team-only API key"
266- raise Notifications ::Client ::BadRequestError , response
267- }
268-
269- EventMailer . stub ( :request_fact_check , raises_exception ) do
270- @simple_smart_answer . update! ( state : "ready" )
271- visit_edition @simple_smart_answer
272-
273- click_link ( "Fact check" )
274-
275- within "#send_fact_check_form" do
276- fill_in "Customised message" , with : "Blah blah fact check message"
277- fill_in "Email address" , with : "user-to-ask-for-fact-check@example.com"
278- click_on "Send"
279- end
280-
281- assert page . has_content? "Error: One or more recipients not in GOV.UK Notify team (code: 400).\n This error will not occur in Production."
282- end
283- end
284-
285261 should "be able to send simple smart answer for review" do
286262 @simple_smart_answer . assigned_to = bob
287263
You can’t perform that action at this time.
0 commit comments