Sha256: b031d0bc0be40bf8ca43743fec6182f926549c622f6453017a846aca891c1819
Contents?: true
Size: 716 Bytes
Versions: 2
Compression:
Stored size: 716 Bytes
Contents
require File.expand_path('../test_helper', __FILE__) module Loquor class RepresentationTest < Minitest::Test class FoobarRepresentation extend Representation::ClassMethods include Representation::InstanceMethods def build_path "/foobar" end def self.path "/foobar" end end def test_find_should_get_correct_path_with_simple_path id = 8 Loquor.expects(:get).with("/foobar/#{id}") FoobarRepresentation.find(id) end def test_where_should_get_correct_path_with_simple_path email = "foobar" Loquor.expects(:get).with("/foobar?email=#{email}") FoobarRepresentation.where(email: email).to_a end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
loquor-0.0.2 | test/representation_test.rb |
loquor-0.0.1 | test/representation_test.rb |