Allow translation content styling through scrubber

This commit is contained in:
pfischbeck committed 2019-02-13 09:10:29 +01:00
1 parent 318590e1c7
commit 7cfbc3d9f8
8 files changed
+37 -6

No files matched your search

@@ -27,9 +27,9 @@ class Admin::DashboardControllerTest < ActionDispatch::IntegrationTest
test "should fail incorrect problem count" do
login_admin
post admin_dashboard_update_problem_count_url(problem_count: 2)
post admin_dashboard_update_problem_count_url(problem_count: 3)
assert_redirected_to admin_dashboard_index_url
assert_equal 3, Problem.count
assert_equal 4, Problem.count
end
end
@@ -22,4 +22,12 @@ class ProblemsControllerTest < ActionDispatch::IntegrationTest
assert_redirected_to problem_path(id: 2)
end
test "should contain HTML styles in translation content" do
get problem_url(id: 4)
assert_response :success
assert_select ".problem-content" do
assert_select "b", 1
assert_select 'p[style="text-align:center;"]', 1
end
end
end