0
私は/ spec/supportディレクトリに共有コンテキストを持っています。これは、それを含むものだけでなく、すべての例で今呼び出されています。サポートディレクトリについて特別なことはありますか?また、すべての例でそれを実行したくない場合はどこに置くべきですか?ここですべての例がサポートディレクトリの共有コンテキストに呼び出されましたか?
は、コンテキスト・ファイルです:(各)
require 'spec_helper'
shared_context "timeout context", :timeout do
around(:each) do |example|
timeout = example.metadata[:timeout] || 1.second
Rails.logger.debug "timeout #{timeout} sec for: #{example.metadata[:example_group][:file_path].gsub(/.*?\/spec\//, '')}"
Timeout::timeout(timeout) {
example.run
}
end
end
は周りに多分関連し、この問題ですか?