Sha256: 08e83c1ded9b2679a7383747112d4fbed961fce66d3e573d2aca8c494a40ea68

Contents?: true

Size: 751 Bytes

Versions: 1

Compression:

Stored size: 751 Bytes

Contents

require File.dirname(__FILE__) + '/../../../../test/test_helper'
require File.dirname(__FILE__) + '/testing_helper'

class ACell < Cell::Base
  def existing_view
    @a = "a"; render
  end
end

### DISCUSS: rename file. just found out that rails automagically tries to load a file named
### after the test, which fails with RailsExtensions.

class RenderCellTest < ActionController::TestCase
  include CellsTestMethods
  include Cell::ActionController
  
  def test_render_cell
    assert_equal "A/existing_view/a", render_cell(:a, :existing_view)
  end
  
  # #render_cell_to_string is just an alias of #render_cell
  def test_render_cell_to_string
    assert_equal render_cell_to_string(:a, :existing_view), render_cell(:a, :existing_view)
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
cells-2.3.0 test/rails_extensions_test.rb