Sha256: e1be59f8676ae353350a2ec585d76f5a335c73ec8fdb2a3bf92612fdd709064f

Contents?: true

Size: 619 Bytes

Versions: 1

Compression:

Stored size: 619 Bytes

Contents

require 'spec_helper'
require 'boot_polish'

describe "adding benchmarking aspects" do
  describe ".require" do
    it "benchmarks the require using require_benchmark.nest" do
      benchmark = double(:benchmark)

      benchmark.should_receive(:nest).
        with("require fixtures/dummy.rb").
        and_yield()

      benchmark.should_receive(:nest).
        any_number_of_times.
        with(anything).
        and_yield()


      BootPolish::Base.should_receive(:require_benchmark).
        any_number_of_times.
        and_return(benchmark)

      require('fixtures/dummy.rb').should be_true
    end

  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
boot_polish-0.0.1 spec/boot_polish_spec.rb