Sha256: 2f604d8598b30d0a99f16b8f41355f668deb2582a9b3c6933c2bc6c7366060da

Contents?: true

Size: 1.69 KB

Versions: 5

Compression:

Stored size: 1.69 KB

Contents

begin
  require 'simplecov'
  SimpleCov.start
rescue LoadError
end
ENV["RAILS_ENV"] ||= 'test'
require "sprockets/railtie"
require "rails-footnotes"
require 'capybara/rspec'

module FooBar
  class Application < Rails::Application
    config.secret_key_base = 'foobar'
    config.root = Dir.new('./spec')
    config.eager_load = false
  end
end

ActionController::Base.class_eval do
  include Rails.application.routes.url_helpers
end

class ApplicationController < ActionController::Base
end

module Helpers
  def page
    Capybara::Node::Simple.new(response.body)
  end
end

RSpec.configure do |config|

  Rails.application.initialize!

  config.include Capybara::DSL
  config.include Helpers
  config.example_status_persistence_file_path = ".rspec_results"

  Rails.application.routes.draw do
    get 'footnotes/foo'
    get 'footnotes/foo_holder'
    get 'footnotes/foo_js'
    get 'footnotes/foo_download'
    get 'partials/index'
    get 'files/index'
  end
end

require 'rspec/rails'
require 'capybara/rails'

HTML_DOCUMENT = <<EOF
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
    <head>
        <title>HTML to XHTML Example: HTML page</title>
        <link rel="Stylesheet" href="htmltohxhtml.css" type="text/css" media="screen">
        <meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
    </head>
    <body>
        <p>This is the HTML page. It works and is encoded just like any HTML page you
         have previously done. View <a href="htmltoxhtml2.htm">the XHTML version</a> of
         this page to view the difference between HTML and XHTML.</p>
        <p>You will be glad to know that no changes need to be made to any of your CSS files.</p>
    </body>
</html>
EOF

Version data entries

5 entries across 5 versions & 2 rubygems

Version Path
rails-footnotes-7.0.0 spec/spec_helper.rb
rails-footnotes-5.0.0 spec/spec_helper.rb
rails6-footnotes-5.0.2 spec/spec_helper.rb
rails6-footnotes-5.0.1 spec/spec_helper.rb
rails6-footnotes-5.0.0 spec/spec_helper.rb