Sha256: 5386c2ff73bc2295e05ea7323bb49b4d25aa6c6069894ca65a37bd28382a028a

Contents?: true

Size: 814 Bytes

Versions: 1

Compression:

Stored size: 814 Bytes

Contents

require 'test_helper'

class FineUploaderTest < ActionDispatch::IntegrationTest
  teardown { clean_cache }

  test "engine is loaded" do
    assert_equal ::Rails::Engine, FineUploader::Rails::Engine.superclass
  end

  test "javascript is served" do
    get "/assets/fine_uploader.js"
    assert_response :success
  end

  test "images are served" do
    get "/assets/fine_uploader/loading.gif"
    get "/assets/fine_uploader/processing.gif"
    assert_response :success
  end

  test "stylesheet contain references to images" do
    get "/assets/fine_uploader.css"
    assert_match "/assets/fine_uploader/loading.gif", response.body
    assert_match "/assets/fine_uploader/processing.gif", response.body
  end

  private
  def clean_cache
    FileUtils.rm_rf File.expand_path("../dummy/tmp",  __FILE__)
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
fine_uploader-3.5.0 test/fine_uploader_test.rb