Sha256: 52400100a993acd3f5177a384b8abd459889a6a7e811c918dbbc4ed2c58024d8

Contents?: true

Size: 344 Bytes

Versions: 11

Compression:

Stored size: 344 Bytes

Contents

describe Nanoc::Telemetry::Counter do
  subject(:counter) { described_class.new }

  it 'starts at 0' do
    expect(counter.value).to eq(0)
  end

  describe '#increment' do
    subject { counter.increment }

    it 'increments' do
      expect { subject }
        .to change { counter.value }
        .from(0)
        .to(1)
    end
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
nanoc-4.7.9 spec/nanoc/telemetry/counter_spec.rb
nanoc-4.7.8 spec/nanoc/telemetry/counter_spec.rb
nanoc-4.7.7 spec/nanoc/telemetry/counter_spec.rb
nanoc-4.7.6 spec/nanoc/telemetry/counter_spec.rb
nanoc-4.7.5 spec/nanoc/telemetry/counter_spec.rb
nanoc-4.7.4 spec/nanoc/telemetry/counter_spec.rb
nanoc-4.7.3 spec/nanoc/telemetry/counter_spec.rb
nanoc-4.7.2 spec/nanoc/telemetry/counter_spec.rb
nanoc-4.7.1 spec/nanoc/telemetry/counter_spec.rb
nanoc-4.7.0 spec/nanoc/telemetry/counter_spec.rb
nanoc-4.6.4 spec/nanoc/telemetry/counter_spec.rb