Sha256: b7547a7d7f8da189179c5e4329c5d62289137958dbc1d0aea87a15d3bf99534c
Contents?: true
Size: 1.15 KB
Versions: 26
Compression:
Stored size: 1.15 KB
Contents
require 'test_helper' class InvalidRenderer end class ActiveListTest < ActiveSupport::TestCase # include AppMockHelper def test_add_renderer assert_raise ArgumentError do ActiveList.register_renderer(InvalidRenderer) end end def test_existing_renderers assert ActiveList.renderers.any?, 'No renderer found' ActiveList.renderers.each do |name, renderer| assert renderer.instance_methods.include?(:remote_update_code), "Renderer #{name} does not respond to :remote_update_code" assert renderer.instance_methods.include?(:build_data_code), "Renderer #{name} does not respond to :build_data_code" end end def test_existing_exporters assert ActiveList.exporters.any?, 'No exporter found' ActiveList.exporters.each do |name, exporter| assert exporter.instance_methods.include?(:send_data_code), "Exporter #{name} does not respond to :send_data_code" assert exporter.instance_methods.include?(:mime_type), "Exporter #{name} does not respond to :mime_type" assert exporter.instance_methods.include?(:file_extension), "Exporter #{name} does not respond to :file_extension" end end end
Version data entries
26 entries across 26 versions & 1 rubygems