Skip to content

Instantly share code, notes, and snippets.

@hanachin
Last active December 13, 2018 14:34
Show Gist options
  • Save hanachin/329fc322e5ecb493b424b50e512132b6 to your computer and use it in GitHub Desktop.
Save hanachin/329fc322e5ecb493b424b50e512132b6 to your computer and use it in GitHub Desktop.
Turnipで書いたfeatureにパスに応じて異なるtypeをつける方法 ref: https://qiita.com/hanachin_/items/e3ad66bbff4da97efafd
RSpec.configure do |config|
config.define_derived_metadata(:file_path => %r{/spec/models/.*.feature}) do |metadata|
metadata[:type] = :model
end
end
Turnip.type = :system
RSpec.configure do |config|
config.define_derived_metadata(:file_path => %r{/spec/models/.*.feature}) do |metadata|
metadata[:type] = :model
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment