Sha256: 6645a228e1af8ed455137e1a0f35615f7353d41097d149043bfd5a94cebcd292

Contents?: true

Size: 621 Bytes

Versions: 2

Compression:

Stored size: 621 Bytes

Contents

require 'spec_helper'

describe Jasmine::Headless::FileChecker do
  include FakeFS::SpecHelpers

  let(:test_class) do
    object = Object.new
    object.class.send(:include, Jasmine::Headless::FileChecker)
    object
  end

  context "bad_format?" do
    it "should return false wth correct format" do
      test_class.bad_format?('foobar.js').should be_false
    end

    it "should return false wth wrong format" do
      test_class.bad_format?('foobar.js.erb').should be_true
    end

    it "should check for the whole extension" do
      test_class.bad_format?('foobar.string.js').should be_false
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
jasmine-headless-webkit-0.8.4 spec/lib/jasmine/headless/file_checker_spec.rb
jasmine-headless-webkit-0.8.3 spec/lib/jasmine/headless/file_checker_spec.rb