Sha256: 7e697588df43c4ec52dfd18db45fdbd9de34cc2ae73f7773ba1a6178262e343f
Contents?: true
Size: 642 Bytes
Versions: 18
Compression:
Stored size: 642 Bytes
Contents
require "spec_helper" describe TmpConfig do describe "#new(contents)" do it "creates a config file" do file_contents = "contents\ncontents" @tmp_config = TmpConfig.new(file_contents) tmp_config_file = File.join(@tmp_config.path, "config") expect(File.exist?(tmp_config_file)).to be true contents = File.read(tmp_config_file) expect(contents).to eql(file_contents) @tmp_config.close end end describe "#path" do it "returns a string" do @tmp_config = TmpConfig.new("contents") expect(@tmp_config.path).to be_kind_of(String) @tmp_config.close end end end
Version data entries
18 entries across 18 versions & 1 rubygems