MCPcopy Create free account
hub / github.com/sqlalchemy/sqlalchemy / test_len

Method test_len

test/sql/test_resultset.py:1612–1624  ·  view source on GitHub ↗
(self, connection)

Source from the content-addressed store, hash-verified

1610 )
1611
1612 def test_len(self, connection):
1613 users = self.tables.users
1614
1615 connection.execute(users.insert(), dict(user_id=1, user_name="foo"))
1616 r = connection.execute(users.select()).first()
1617 eq_(len(r), 2)
1618
1619 r = connection.exec_driver_sql(
1620 "select user_name, user_id from users"
1621 ).first()
1622 eq_(len(r), 2)
1623 r = connection.exec_driver_sql("select user_name from users").first()
1624 eq_(len(r), 1)
1625
1626 def test_row_mapping_get(self, connection):
1627 users = self.tables.users

Callers

nothing calls this directly

Calls 6

eq_Function · 0.90
executeMethod · 0.45
insertMethod · 0.45
firstMethod · 0.45
selectMethod · 0.45
exec_driver_sqlMethod · 0.45

Tested by

no test coverage detected