Sha256: 0bf50c175faed3f1af8d73d78319f9b25b28289d806da43a0b4dcb7153af4d96

Contents?: true

Size: 686 Bytes

Versions: 48

Compression:

Stored size: 686 Bytes

Contents

# frozen_string_literal: true

require "active_record_unit"

class RelationCacheTest < ActionView::TestCase
  tests ActionView::Helpers::CacheHelper

  def setup
    view_paths     = ActionController::Base.view_paths
    lookup_context = ActionView::LookupContext.new(view_paths, {}, ["test"])
    @view_renderer = ActionView::Renderer.new(lookup_context)
    @virtual_path  = "path"

    controller.cache_store = ActiveSupport::Cache::MemoryStore.new
  end

  def test_cache_relation_other
    cache(Project.all) { concat("Hello World") }
    assert_equal "Hello World", controller.cache_store.read("views/path/projects-#{Project.count}")
  end

  def view_cache_dependencies; end
end

Version data entries

48 entries across 48 versions & 2 rubygems

Version Path
jets-1.5.6 vendor/rails/actionview/test/activerecord/relation_cache_test.rb
jets-1.5.5 vendor/rails/actionview/test/activerecord/relation_cache_test.rb
jets-1.5.4 vendor/rails/actionview/test/activerecord/relation_cache_test.rb
jets-1.5.3 vendor/rails/actionview/test/activerecord/relation_cache_test.rb
jets-1.5.2 vendor/rails/actionview/test/activerecord/relation_cache_test.rb
jets-1.5.1 vendor/rails/actionview/test/activerecord/relation_cache_test.rb
jets-1.5.0 vendor/rails/actionview/test/activerecord/relation_cache_test.rb
ruby-on-quails-0.1.0 actionview/test/activerecord/relation_cache_test.rb