Sha256: 1f82873e1ebb84698607152634e5c257a8386969eaf1d51c0a1d34b99eff85c9

Contents?: true

Size: 509 Bytes

Versions: 1

Compression:

Stored size: 509 Bytes

Contents

require "spec_helper"

RSpec.describe Time do
  describe "#to_burlap" do
    subject(:burlap) { described_class.utc(2011, 9, 11, 10, 0).to_burlap }

    it "returns a string" do
      expect(burlap).to be_a_kind_of(String)
    end

    it "is correct" do
      expect(burlap).to eq("<date>20110911T100000.000Z</date>")
    end

    it "does not contain dashes" do
      expect(burlap).not_to include("-")
    end

    it "does not contain colons" do
      expect(burlap).not_to include(":")
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
burlap-1.0.0 spec/burlap/core_ext/time_spec.rb