Sha256: 15cd403cafe740bab52978d08451c202a633bc40bf66d3a7735f99c91d44dd46

Contents?: true

Size: 521 Bytes

Versions: 1

Compression:

Stored size: 521 Bytes

Contents

require 'spec_helper'

require 'state_mate/adapters/defaults'

describe "StateMate::Adapters::Defaults.read" do
  include_context "defaults"
  include_context "#{ DOMAIN } empty"

  let(:key) {
    'x'
  }

  context "key has string value" do

    let(:string) {
      'blah!'
    }

    before(:each) {
      `defaults write #{ DOMAIN } #{ key } -string '#{ string }' 2>&1`
    }

    it "deletes value" do
      defaults.write [DOMAIN, key], nil
      expect( defaults.read [DOMAIN, key] ).to eq nil
    end
  end

end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
state_mate-0.0.1 spec/state_mate/adapters/defaults/write_spec.rb