Sha256: 35891ea76a9b53c7a6d0024ee9df3f5b5702e8a6ec106de43e7fc56b1cfc83fb
Contents?: true
Size: 665 Bytes
Versions: 22
Compression:
Stored size: 665 Bytes
Contents
require 'test_plugin_helper' class OpenscapProxiesControllerTest < ActionController::TestCase include ActionView::Helpers::DateHelper test "should render spool error" do spool_error = { "timestamp" => 1_487_144_633.951_368, "level" => "ERROR", "message"=> "Failed to parse Arf Report in test" } OpenscapProxiesController.any_instance.stubs(:find_spool_error).returns(spool_error) proxy = FactoryGirl.create(:openscap_proxy) get :openscap_spool, { :id => proxy.id }, set_session_user assert_template :partial => 'smart_proxies/_openscap_spool' assert @response.body.match(time_ago_in_words(Time.at(spool_error["timestamp"]))) end end
Version data entries
22 entries across 22 versions & 1 rubygems