Sha256: 900eb94cea3920ddb646926cc54c2f6b84a65acef3c084ff936e919a12be9d92

Contents?: true

Size: 741 Bytes

Versions: 33

Compression:

Stored size: 741 Bytes

Contents

require "spec_helper"
require "octopolo/semver_tag_scrubber"

module Octopolo
  describe SemverTagScrubber do
    let(:tag) { "Prefix0.0.1Suffix" }

    describe "::scrub_prefix" do
      it "returns the prefix" do
        expect(SemverTagScrubber.scrub_prefix tag).to eq("Prefix")
      end

      it "scrub the prefix from the tag" do
        SemverTagScrubber.scrub_prefix tag
        expect(tag).to eq("0.0.1Suffix")
      end
    end

    describe "::scrub_suffix" do
      it "returns the suffix" do
        expect(SemverTagScrubber.scrub_suffix tag).to eq("Suffix")
      end

      it "scrub the suffix from the tag" do
        SemverTagScrubber.scrub_suffix tag
        expect(tag).to eq("Prefix0.0.1")
      end
    end

  end
end

Version data entries

33 entries across 33 versions & 1 rubygems

Version Path
octopolo-1.11.1 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.11.0 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.9.0 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.8.1 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.8.0 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.7.1 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.7.0 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.6.0 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.5.3 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.5.2 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.5.1 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.5.0 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.4.0 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.3.0 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.2.1 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.2.0 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.1.1 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.1.0 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.0.2 spec/octopolo/semver_tag_scrubber_spec.rb
octopolo-1.0.1 spec/octopolo/semver_tag_scrubber_spec.rb