Sha256: 4b3e441414d38a681d806c478088e340947c99abb152fe6ef7d5c9caf96a5df4
Contents?: true
Size: 1.26 KB
Versions: 4
Compression:
Stored size: 1.26 KB
Contents
# encoding: utf-8 describe Hexx::RSpec do let(:coverage_settings) { described_class::Metrics::SimpleCov } let(:rake_tasks) { Rake::Task.tasks.map(&:name) } describe ".install_tasks" do before { described_class.install_tasks } it "installs Gem tasks" do expect(rake_tasks).to include("build", "install", "release") end it "installs RSpec tasks" do expect(rake_tasks).to include("spec") end it "installs described_class tasks" do expect(rake_tasks).to include(*%w( test:coverage test:coverage:display test:coverage:run test )) end end # display .insall_tasks describe ".load_metrics_for" do subject { described_class.load_metrics_for(double) } context "when ENV[USE_SIMPLECOV] is set" do before { ENV["USE_SIMPLECOV"] = "true" } it "initializes and runs a coverage settings" do expect(coverage_settings).to receive(:run) subject end end context "when ENV[USE_SIMPLECOV] isn't set" do before { ENV["USE_SIMPLECOV"] = nil } it "doesn't run settings" do expect(coverage_settings).not_to receive(:run) subject end end end # display .load_metrics_for end # display Hexx::RSpec
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
hexx-rspec-0.2.1 | spec/tests/rspec_spec.rb |
hexx-rspec-0.2.0 | spec/tests/rspec_spec.rb |
hexx-rspec-0.1.0 | spec/tests/rspec_spec.rb |
hexx-rspec-0.0.1 | spec/tests/rspec_spec.rb |