diff options
author | Rémy Coutable <remy@rymai.me> | 2018-07-18 16:06:53 +0300 |
---|---|---|
committer | Rémy Coutable <remy@rymai.me> | 2018-07-18 16:06:53 +0300 |
commit | d2db7d40dd85aa8e80b6429d7fd6b8df23ecac2a (patch) | |
tree | 332768b9f1edd68c42f08ec2fe31a31e22cf8920 /qa/spec | |
parent | d81189029d072b41434992efb991152842639009 (diff) |
Disambiguate 'File' under qa/ since we have a QA::Factory::Resource::File class as well
Signed-off-by: Rémy Coutable <remy@rymai.me>
Diffstat (limited to 'qa/spec')
-rw-r--r-- | qa/spec/git/repository_spec.rb | 2 | ||||
-rw-r--r-- | qa/spec/page/view_spec.rb | 4 | ||||
-rw-r--r-- | qa/spec/scenario/test/instance_spec.rb | 2 | ||||
-rw-r--r-- | qa/spec/spec_helper.rb | 2 |
4 files changed, 5 insertions, 5 deletions
diff --git a/qa/spec/git/repository_spec.rb b/qa/spec/git/repository_spec.rb index ee1f08da238..5c65128d10c 100644 --- a/qa/spec/git/repository_spec.rb +++ b/qa/spec/git/repository_spec.rb @@ -29,7 +29,7 @@ describe QA::Git::Repository do def cd_empty_temp_directory tmp_dir = 'tmp/git-repository-spec/' - FileUtils.rm_r(tmp_dir) if File.exist?(tmp_dir) + FileUtils.rm_r(tmp_dir) if ::File.exist?(tmp_dir) FileUtils.mkdir_p tmp_dir FileUtils.cd tmp_dir end diff --git a/qa/spec/page/view_spec.rb b/qa/spec/page/view_spec.rb index aedbc3863a7..34d2ff11447 100644 --- a/qa/spec/page/view_spec.rb +++ b/qa/spec/page/view_spec.rb @@ -32,7 +32,7 @@ describe QA::Page::View do context 'when pattern is found' do before do - allow(File).to receive(:foreach) + allow(::File).to receive(:foreach) .and_yield('some element').once allow(element).to receive(:matches?) .with('some element').and_return(true) @@ -45,7 +45,7 @@ describe QA::Page::View do context 'when pattern has not been found' do before do - allow(File).to receive(:foreach) + allow(::File).to receive(:foreach) .and_yield('some element').once allow(element).to receive(:matches?) .with('some element').and_return(false) diff --git a/qa/spec/scenario/test/instance_spec.rb b/qa/spec/scenario/test/instance_spec.rb index a74a9538be8..0d0b534911f 100644 --- a/qa/spec/scenario/test/instance_spec.rb +++ b/qa/spec/scenario/test/instance_spec.rb @@ -30,7 +30,7 @@ describe QA::Scenario::Test::Instance do subject.perform("test") expect(runner).to have_received(:options=) - .with(File.expand_path('../../../qa/specs/features', __dir__)) + .with(::File.expand_path('../../../qa/specs/features', __dir__)) end end diff --git a/qa/spec/spec_helper.rb b/qa/spec/spec_helper.rb index c2c6cf95406..8e6613cd688 100644 --- a/qa/spec/spec_helper.rb +++ b/qa/spec/spec_helper.rb @@ -1,6 +1,6 @@ require_relative '../qa' -Dir[File.join(__dir__, 'support', '**', '*.rb')].each { |f| require f } +Dir[::File.join(__dir__, 'support', '**', '*.rb')].each { |f| require f } RSpec.configure do |config| config.expect_with :rspec do |expectations| |