Sha256: 9edc45ce019a348bb498041138bab8176384224cb2755e4115e245f978966d2c
Contents?: true
Size: 494 Bytes
Versions: 8
Compression:
Stored size: 494 Bytes
Contents
# encoding: utf-8 # # Copyright (C) 2011-2012 AdMaster, Inc. module Apimaster::Test class Factory def self.define name, value = nil self.attrs[name] = value end def self.attrs @attrs ||= {} end def self.attr key @attrs ||= {} @attrs[key] end def self.register name @klass = name end def self.post data = {} raise "Please register class first." unless @klass @klass.post attrs.merge(data) end end end
Version data entries
8 entries across 8 versions & 1 rubygems