MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / test_gen_path_invalid_from_col

Method test_gen_path_invalid_from_col

test/orm/test_options.py:161–174  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

159 )
160
161 def test_gen_path_invalid_from_col(self):
162 User = self.classes.User
163
164 result = Load(User)
165 result.path = self._make_path_registry([User, "name"])
166 assert_raises_message(
167 sa.exc.ArgumentError,
168 "Attribute 'name' of entity 'Mapper|User|users' does "
169 "not refer to a mapped entity",
170 result._clone_for_bind_strategy,
171 (User.addresses,),
172 None,
173 "relationship",
174 )
175
176 def test_gen_path_attr_entity_invalid_raiseerr(self):
177 User = self.classes.User

Callers

nothing calls this directly

Calls 3

LoadClass · 0.90
assert_raises_messageFunction · 0.90
_make_path_registryMethod · 0.80

Tested by

no test coverage detected