lib/generators/templates/component_test.rb.erb in amber_component-0.0.4 vs lib/generators/templates/component_test.rb.erb in amber_component-0.0.5
- old
+ new
@@ -1,9 +1,17 @@
# frozen_string_literal: true
require 'test_helper'
-class <%= class_name %>Test < ::ActiveSupport::TestCase
- # test 'the truth' do
- # assert true
+class <%= class_name %>Test < ::ApplicationComponentTestCase
+ # For a full list of available assertions see
+ # https://rubydoc.info/github/jnicklas/capybara/Capybara/Node/Matchers
+
+ # test 'returns correct html' do
+ # render do
+ # <%= class_name %>.call
+ # end
+
+ # assert_text 'Hello from <%= class_name %>'
+ # assert_selector "div.<%= singular_table_name %> p", text: 'Default Description'
# end
end