Sha256: d2e4c7a2851cf13b3e8f3b94ea8e1e6d9b54fcdd8704c2633a4590355fdb2e74
Contents?: true
Size: 1.24 KB
Versions: 6
Compression:
Stored size: 1.24 KB
Contents
require File.expand_path(File.dirname(__FILE__) + '/../../test_helper') module ESP::Integration class Stat class ServiceTest < ESP::Integration::TestCase context ESP::StatService do context 'live calls' do context '#services' do should 'return signatures' do report = ESP::Report.all.detect { |r| r.status == 'complete' } fail "Live DB does not have any reports. Add a report with stats and run tests again." if report.blank? stat = ESP::Stat.for_report(report.id) services = stat.services service = services.first.service assert_equal ESP::Service, service.class assert_equal services.first.service.name, service.name end end context '.for_stat' do should 'return tags for stat id' do report = ESP::Report.all.detect { |r| r.status == 'complete' } fail "make sure you have a complete report" unless report.present? stat_id = report.stat.id stats = ESP::StatService.for_stat(stat_id) assert_equal ESP::StatService, stats.resource_class end end end end end end end
Version data entries
6 entries across 6 versions & 1 rubygems