We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 84a0d6b commit 0653d82Copy full SHA for 0653d82
lib/generators/test_unit/scaffold/scaffold_generator.rb
@@ -5,7 +5,9 @@ module Generators # :nodoc:
5
class ScaffoldGenerator < Base # :nodoc:
6
def fix_system_test
7
if turbo_defined?
8
- gsub_file File.join("test/system", class_path, "#{file_name.pluralize}_test.rb"), "click_on \"Destroy this #{human_name.downcase}\", match: :first", "accept_confirm { click_on \"Destroy this #{human_name.downcase}\", match: :first }"
+ gsub_file File.join("test/system", class_path, "#{file_name.pluralize}_test.rb"),
9
+ /(click_on.*Destroy this.*)$/,
10
+ "accept_confirm { \\1 }"
11
end
12
13
0 commit comments