Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Do not change or generate README.md after running rspec #8629

Merged
merged 6 commits into from
Apr 1, 2017
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 2 additions & 0 deletions fastlane/spec/cli_tools_distributor_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,8 @@
end

it "checks for updates even if the lane has an error" do
allow(FastlaneCore::Env).to receive(:truthy?).and_return(:default)
allow(FastlaneCore::Env).to receive(:truthy?).with('FASTLANE_SKIP_DOCS').and_return(true)
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is 3 duplication codes, so it is better to define helper in fastlane_core/spec/spec_helper.rb or fastlane/spec/spec_helper.rb?

FastlaneSpec::Env.with_ARGV(["beta"])
expect(FastlaneCore::FastlaneFolder).to receive(:fastfile_path).and_return("./fastlane/spec/fixtures/fastfiles/FastfileErrorInError").at_least(:once)
expect(FastlaneCore::UpdateChecker).to receive(:start_looking_for_update).with('fastlane')
Expand Down
2 changes: 2 additions & 0 deletions fastlane/spec/commands_generator_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
ENV['DOTENV'] = nil
fastlane_folder = File.absolute_path('./fastlane/spec/fixtures/dotenvs/withFastfiles/parentonly/fastlane')
allow(FastlaneCore::FastlaneFolder).to receive(:path).and_return(fastlane_folder)
allow(FastlaneCore::Env).to receive(:truthy?).and_return(:default)
allow(FastlaneCore::Env).to receive(:truthy?).with('FASTLANE_SKIP_DOCS').and_return(true)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we set this for all tests inside the spec_helper?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes 馃憤

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@KrauseFx Uhh, no after all. I tried to define these in spec_helper, and it had other problems to cause test failure.

end

describe ":trigger option handling" do
Expand Down
2 changes: 2 additions & 0 deletions fastlane/spec/lane_manager_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,8 @@ def ensure_dot_env_value_from_folders(folders, envs, expected_values)
describe "successfull init" do
before do
allow(FastlaneCore::FastlaneFolder).to receive(:path).and_return(File.absolute_path('./fastlane/spec/fixtures/fastfiles/'))
allow(FastlaneCore::Env).to receive(:truthy?).and_return(:default)
allow(FastlaneCore::Env).to receive(:truthy?).with('FASTLANE_SKIP_DOCS').and_return(true)
end

it "Successfully collected all actions" do
Expand Down