Sha256: 77cc531e93e737e3e6e66dc1aab9176e9c0d12db72a788d2069202a81e4f52f5

Contents?: true

Size: 910 Bytes

Versions: 10

Compression:

Stored size: 910 Bytes

Contents

require 'spec_helper'

describe LitmusPaper::StatusFile do
  describe "create" do
    it "creates a nested file" do
      status_file = LitmusPaper::StatusFile.new("foo", "bar")
      status_file.create("for testing")

      status_file.exists?.should == true
    end

    it "creates a file" do
      status_file = LitmusPaper::StatusFile.new("foo")
      status_file.create("for testing")

      status_file.exists?.should == true
    end

    it "writes the content" do
      status_file = LitmusPaper::StatusFile.new("foo")
      status_file.create("for testing")

      status_file.content.should == "for testing"
    end
  end

  describe "delete" do
    it "removes the file" do
      status_file = LitmusPaper::StatusFile.new("foo")
      status_file.create("for testing")

      status_file.exists?.should be_true

      status_file.delete

      status_file.exists?.should be_false
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
litmus_paper-0.3.5 spec/litmus_paper/status_file_spec.rb
litmus_paper-0.3.3 spec/litmus_paper/status_file_spec.rb
litmus_paper-0.3.2 spec/litmus_paper/status_file_spec.rb
litmus_paper-0.3.1 spec/litmus_paper/status_file_spec.rb
litmus_paper-0.3.0 spec/litmus_paper/status_file_spec.rb
litmus_paper-0.2.2 spec/litmus_paper/status_file_spec.rb
litmus_paper-0.2.1 spec/litmus_paper/status_file_spec.rb
litmus_paper-0.2.0 spec/litmus_paper/status_file_spec.rb
litmus_paper-0.1.0 spec/litmus_paper/status_file_spec.rb
litmus_paper-0.0.3 spec/litmus_paper/status_file_spec.rb