Sha256: cd2f85ab4f47df6e25f8a8f8f36717ddbb88fcb8d1aae91e76b7174a2196598c
Contents?: true
Size: 536 Bytes
Versions: 2
Compression:
Stored size: 536 Bytes
Contents
require File.dirname(__FILE__) + '/../spec_helper' require 'mspec/helpers/fmode' describe Object, "#fmode" do it "returns the argument unmodified if :encoding feature is enabled" do FeatureGuard.should_receive(:enabled?).with(:encoding).and_return(true) fmode("rb:binary:utf-8").should == "rb:binary:utf-8" end it "returns only the file access mode if :encoding feature is not enabled" do FeatureGuard.should_receive(:enabled?).with(:encoding).and_return(false) fmode("rb:binary:utf-8").should == "rb" end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
mspec-1.5.17 | spec/helpers/fmode_spec.rb |
mspec-1.5.16 | spec/helpers/fmode_spec.rb |