test_apps/rails/spec/rails_helper.rb in sapience-1.0.9 vs test_apps/rails/spec/rails_helper.rb in sapience-1.0.10
- old
+ new
@@ -13,10 +13,13 @@
Dir[Rails.root.join("spec/support/**/*.rb")].each { |f| require f }
# Checks for pending migration and applies them before tests are run.
# If you are not using ActiveRecord, you can remove this line.
+Sapience.configure do |c|
+ c.app_name = "rails_app"
+end
ActiveRecord::Migration.maintain_test_schema!
RSpec.configure do |config|
config.include FileHelper
# Remove this line if you're not using ActiveRecord or ActiveRecord fixtures
@@ -30,12 +33,9 @@
FileUtils.cp(
Rails.root.join("spec/fixtures/sapience.yml"),
Rails.root.join("config/sapience.yml"),
)
Sapience.reset!
- Sapience.configure do |c|
- c.app_name = "rails_app"
- end
end
config.after(:each) do
sapience_config = Rails.root.join("config/sapience.yml")
FileUtils.rm(sapience_config) if File.exist?(sapience_config)