Sha256: 3da2db31232a44e82c49a2cc94850f80aa1e5f9a480df1d18081b67dc10ff500
Contents?: true
Size: 920 Bytes
Versions: 1
Compression:
Stored size: 920 Bytes
Contents
require 'api-tester/reporter/status_code_report' require 'api-tester/modules/module' require 'api-tester/method_case_test' module ApiTester class GoodCase < Module def go endpoint, report super endpoint.methods.each do |method| default_case = BoundaryCase.new endpoint.url, method.request.default_payload, method.request.default_headers response = endpoint.call method, default_case.payload, default_case.headers test = GoodCaseTest.new response, endpoint.url, method self.report.reports.concat test.check end self.report.reports == [] end def order 1 end end class GoodCaseTest < MethodCaseTest def initialize response, url, method super response, method.request.default_payload, method.expected_response, url, method.verb, "GoodCaseModule" end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
api-tester-0.2.0 | lib/api-tester/modules/good_case.rb |