Sha256: 51cf6c88916ca1766dec4a3e53b7d9ab3b3a6ca5b91547efbcc57b6af2baa9d4

Contents?: true

Size: 659 Bytes

Versions: 2

Compression:

Stored size: 659 Bytes

Contents

require "webpacker_test"

class CompilerTest < Minitest::Test
  def test_default_watched_paths
    assert_equal Webpacker::Compiler.default_watched_paths, ["app/javascript/**/*", "yarn.lock", "package.json", "config/webpack/**/*"]
  end

  def test_empty_watched_paths
    assert_equal Webpacker::Compiler.watched_paths, []
  end

  def test_watched_paths
    Webpacker::Compiler.stub :watched_paths, ["Gemfile"] do
      assert_equal Webpacker::Compiler.watched_paths, ["Gemfile"]
    end
  end

  def test_cache_dir
    assert_equal Webpacker::Compiler.cache_dir, "tmp/webpacker"
  end

  def test_compile?
    assert Webpacker::Compiler.compile?
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
webpacker-react-on-rails-3.0.0.rc.1 test/compiler_test.rb
webpacker-react-on-rails-2.0 test/compiler_test.rb