Improve testing on docker

This commit is contained in:
wvengen 2020-07-27 17:39:56 +02:00
parent b96ce06d94
commit ef1903381b
6 changed files with 16 additions and 13 deletions

View file

@ -53,16 +53,6 @@ RSpec.configure do |config|
config.infer_spec_type_from_file_location!
end
module Faker
class Unit
class << self
def unit
['kg', '1L', '100ml', 'piece', 'bunch', '500g'].sample
end
end
end
end
# include default foodsoft scope in urls, so that *_path works
# https://github.com/rspec/rspec-rails/issues/255
class ActionDispatch::Routing::RouteSet

View file

@ -1,4 +1,4 @@
RSpec.configure do |config|
# load FactoryBot shortcuts create(), etc.
config.include FactoryBot::Syntax::Methods
end
end

10
spec/support/faker.rb Normal file
View file

@ -0,0 +1,10 @@
module Faker
class Unit
class << self
def unit
['kg', '1L', '100ml', 'piece', 'bunch', '500g'].sample
end
end
end
end