diff options
Diffstat (limited to 'test/orm')
| -rw-r--r-- | test/orm/inheritance/test_basic.py | 2 | ||||
| -rw-r--r-- | test/orm/test_assorted_eager.py | 2 | ||||
| -rw-r--r-- | test/orm/test_attributes.py | 4 | ||||
| -rw-r--r-- | test/orm/test_backref_mutations.py | 2 | ||||
| -rw-r--r-- | test/orm/test_cycles.py | 4 | ||||
| -rw-r--r-- | test/orm/test_deferred.py | 4 | ||||
| -rw-r--r-- | test/orm/test_expire.py | 6 | ||||
| -rw-r--r-- | test/orm/test_froms.py | 4 | ||||
| -rw-r--r-- | test/orm/test_mapper.py | 4 | ||||
| -rw-r--r-- | test/orm/test_merge.py | 6 | ||||
| -rw-r--r-- | test/orm/test_naturalpks.py | 2 | ||||
| -rw-r--r-- | test/orm/test_query.py | 4 | ||||
| -rw-r--r-- | test/orm/test_session.py | 2 | ||||
| -rw-r--r-- | test/orm/test_unitofwork.py | 4 | ||||
| -rw-r--r-- | test/orm/test_versioning.py | 2 |
15 files changed, 26 insertions, 26 deletions
diff --git a/test/orm/inheritance/test_basic.py b/test/orm/inheritance/test_basic.py index 1737d1ccb..c3128d264 100644 --- a/test/orm/inheritance/test_basic.py +++ b/test/orm/inheritance/test_basic.py @@ -1095,7 +1095,7 @@ class FlushTest(fixtures.MappedTest): # create an Admin, and append a Role. the dependency processors # corresponding to the "roles" attribute for the Admin mapper and the User mapper - # have to ensure that two dependency processors dont fire off and insert the + # have to ensure that two dependency processors don't fire off and insert the # many to many row twice. a = Admin() a.roles.append(adminrole) diff --git a/test/orm/test_assorted_eager.py b/test/orm/test_assorted_eager.py index 09c8ea732..d00da77f5 100644 --- a/test/orm/test_assorted_eager.py +++ b/test/orm/test_assorted_eager.py @@ -289,7 +289,7 @@ class EagerTest2(fixtures.MappedTest): def test_eager_terminate(self): """Eager query generation does not include the same mapper's table twice. - Or, that bi-directional eager loads dont include each other in eager + Or, that bi-directional eager loads don't include each other in eager query generation. """ diff --git a/test/orm/test_attributes.py b/test/orm/test_attributes.py index a7c675175..ccb1effdb 100644 --- a/test/orm/test_attributes.py +++ b/test/orm/test_attributes.py @@ -218,7 +218,7 @@ class AttributesTest(fixtures.ORMTest): attributes.register_attribute(MyTest2, 'b', uselist=False, useobject=False) - # shouldnt be pickling callables at the class level + # shouldn't be pickling callables at the class level def somecallable(state, passive): return None @@ -1298,7 +1298,7 @@ class PendingBackrefTest(fixtures.ORMTest): p = Post("post 5") - # setting blog doesnt call 'posts' callable, calls with no fetch + # setting blog doesn't call 'posts' callable, calls with no fetch p.blog = b eq_( lazy_posts.mock_calls, [ diff --git a/test/orm/test_backref_mutations.py b/test/orm/test_backref_mutations.py index e9448d41c..67f8c6c00 100644 --- a/test/orm/test_backref_mutations.py +++ b/test/orm/test_backref_mutations.py @@ -393,7 +393,7 @@ class O2OScalarBackrefMoveTest(_fixtures.FixtureTest): # backref fires assert u1.address is a2 - # didnt work this way tho + # didn't work this way tho assert a1.user is u1 # moves appropriately after commit diff --git a/test/orm/test_cycles.py b/test/orm/test_cycles.py index 1da57b050..59f8198f0 100644 --- a/test/orm/test_cycles.py +++ b/test/orm/test_cycles.py @@ -383,7 +383,7 @@ class BiDirectionalManyToOneTest(fixtures.MappedTest): # the bug here is that the dependency sort comes up with T1/T2 in a # cycle, but there are no T1/T2 objects to be saved. therefore no # "cyclical subtree" gets generated, and one or the other of T1/T2 - # gets lost, and processors on T3 dont fire off. the test will then + # gets lost, and processors on T3 don't fire off. the test will then # fail because the FK's on T3 are not nullable. o3 = T3() o3.t1 = o1 @@ -592,7 +592,7 @@ class OneToManyManyToOneTest(fixtures.MappedTest): def test_cycle(self): """ - This test has a peculiar aspect in that it doesnt create as many + This test has a peculiar aspect in that it doesn't create as many dependent relationships as the other tests, and revealed a small glitch in the circular dependency sorting. diff --git a/test/orm/test_deferred.py b/test/orm/test_deferred.py index 88e7e8663..d96d420e7 100644 --- a/test/orm/test_deferred.py +++ b/test/orm/test_deferred.py @@ -80,7 +80,7 @@ class DeferredTest(AssertsCompiledSQL, _fixtures.FixtureTest): self.sql_count_(0, go) def test_unsaved_group(self): - """Deferred loading doesnt kick in when just PK cols are set""" + """Deferred loading doesn't kick in when just PK cols are set""" orders, Order = self.tables.orders, self.classes.Order @@ -204,7 +204,7 @@ class DeferredTest(AssertsCompiledSQL, _fixtures.FixtureTest): assert o2 not in sess.dirty # this will mark it as 'dirty', but nothing actually changed o2.description = 'order 3' - # therefore the flush() shouldnt actually issue any SQL + # therefore the flush() shouldn't actually issue any SQL self.assert_sql_count(testing.db, sess.flush, 0) def test_map_selectable_wo_deferred(self): diff --git a/test/orm/test_expire.py b/test/orm/test_expire.py index edd243181..150a1cb27 100644 --- a/test/orm/test_expire.py +++ b/test/orm/test_expire.py @@ -46,7 +46,7 @@ class ExpireTest(_fixtures.FixtureTest): # change the value in the DB users.update(users.c.id==7, values=dict(name='jack')).execute() sess.expire(u) - # object isnt refreshed yet, using dict to bypass trigger + # object isn't refreshed yet, using dict to bypass trigger assert u.__dict__.get('name') != 'jack' assert 'name' in attributes.instance_state(u).expired_attributes @@ -666,7 +666,7 @@ class ExpireTest(_fixtures.FixtureTest): assert 'addresses' not in u.__dict__ # hit the lazy loader. just does the lazy load, - # doesnt do the overall refresh + # doesn't do the overall refresh def go(): assert u.addresses[0].email_address=='ed@wood.com' self.assert_sql_count(testing.db, go, 1) @@ -1394,7 +1394,7 @@ class RefreshTest(_fixtures.FixtureTest): def test_refresh_with_lazy(self): """test that when a lazy loader is set as a trigger on an object's attribute - (at the attribute level, not the class level), a refresh() operation doesnt + (at the attribute level, not the class level), a refresh() operation doesn't fire the lazy loader or create any problems""" User, Address, addresses, users = (self.classes.User, diff --git a/test/orm/test_froms.py b/test/orm/test_froms.py index fd4bef71a..64e98e745 100644 --- a/test/orm/test_froms.py +++ b/test/orm/test_froms.py @@ -2408,8 +2408,8 @@ class TestOverlyEagerEquivalentCols(fixtures.MappedTest): sess.add(b2) sess.flush() - # theres an overlapping ForeignKey here, so not much option except - # to artifically control the flush order + # there's an overlapping ForeignKey here, so not much option except + # to artificially control the flush order b2.sub2 = [s2] sess.flush() diff --git a/test/orm/test_mapper.py b/test/orm/test_mapper.py index 32126e0dd..78f563b70 100644 --- a/test/orm/test_mapper.py +++ b/test/orm/test_mapper.py @@ -65,7 +65,7 @@ class MapperTest(_fixtures.FixtureTest, AssertsCompiledSQL): x = "something" @property def y(self): - return "somethign else" + return "something else" m = mapper(Foo, users, properties={"addresses":relationship(Address)}) @@ -102,7 +102,7 @@ class MapperTest(_fixtures.FixtureTest, AssertsCompiledSQL): x = "something" @property def y(self): - return "somethign else" + return "something else" m = mapper(Foo, users) a1 = aliased(Foo) diff --git a/test/orm/test_merge.py b/test/orm/test_merge.py index 494f5e349..a52274896 100644 --- a/test/orm/test_merge.py +++ b/test/orm/test_merge.py @@ -748,7 +748,7 @@ class MergeTest(_fixtures.FixtureTest): 'converted' to represent the correct objects. However, at the moment I'd rather not support this use case; if you are merging with load=False, you're typically dealing with caching and the - merged objects shouldnt be 'dirty'. + merged objects shouldn't be 'dirty'. """ @@ -782,7 +782,7 @@ class MergeTest(_fixtures.FixtureTest): self.assert_sql_count(testing.db, go, 0) def test_no_load_disallows_dirty(self): - """load=False doesnt support 'dirty' objects right now + """load=False doesn't support 'dirty' objects right now (see test_no_load_with_eager()). Therefore lets assert it. @@ -899,7 +899,7 @@ class MergeTest(_fixtures.FixtureTest): 'somenewaddress') # this use case is not supported; this is with a pending Address - # on the pre-merged object, and we currently dont support + # on the pre-merged object, and we currently don't support # 'dirty' objects being merged with load=False. in this case, # the empty '_state.parents' collection would be an issue, since # the optimistic flag is False in _is_orphan() for pending diff --git a/test/orm/test_naturalpks.py b/test/orm/test_naturalpks.py index 8c675b94d..011667651 100644 --- a/test/orm/test_naturalpks.py +++ b/test/orm/test_naturalpks.py @@ -108,7 +108,7 @@ class NaturalPKTest(fixtures.MappedTest): users.update(values={User.username:'jack'}).execute(username='ed') # expire/refresh works off of primary key. the PK is gone - # in this case so theres no way to look it up. criterion- + # in this case so there's no way to look it up. criterion- # based session invalidation could solve this [ticket:911] sess.expire(u1) assert_raises(sa.orm.exc.ObjectDeletedError, getattr, u1, 'username') diff --git a/test/orm/test_query.py b/test/orm/test_query.py index 3b483b7c0..bb731db5c 100644 --- a/test/orm/test_query.py +++ b/test/orm/test_query.py @@ -550,7 +550,7 @@ class GetTest(QueryTest): u.addresses[0].email_address = 'lala' u.orders[1].items[2].description = 'item 12' - # test that lazy load doesnt change child items + # test that lazy load doesn't change child items s.query(User).populate_existing().all() assert u.addresses[0].email_address == 'lala' assert u.orders[1].items[2].description == 'item 12' @@ -1383,7 +1383,7 @@ class FilterTest(QueryTest, AssertsCompiledSQL): assert [Address(id=2), Address(id=3), Address(id=4)] == \ sess.query(Address).join("user").filter(Address.user.has(User.name.like('%ed%'), id=8)).order_by(Address.id).all() - # test has() doesnt' get subquery contents adapted by aliased join + # test has() doesn't get subquery contents adapted by aliased join assert [Address(id=2), Address(id=3), Address(id=4)] == \ sess.query(Address).join("user", aliased=True).filter(Address.user.has(User.name.like('%ed%'), id=8)).order_by(Address.id).all() diff --git a/test/orm/test_session.py b/test/orm/test_session.py index b68810036..186b7a781 100644 --- a/test/orm/test_session.py +++ b/test/orm/test_session.py @@ -895,7 +895,7 @@ class SessionStateWFixtureTest(_fixtures.FixtureTest): assert len(u.addresses) == 3 assert newad not in u.addresses - # pending objects dont get expired + # pending objects don't get expired assert newad.email_address == 'a new address' def test_expunge_cascade(self): diff --git a/test/orm/test_unitofwork.py b/test/orm/test_unitofwork.py index 4776e2988..ada2e6c6f 100644 --- a/test/orm/test_unitofwork.py +++ b/test/orm/test_unitofwork.py @@ -1310,7 +1310,7 @@ class SaveTest(_fixtures.FixtureTest): session.add_all((u, u2)) session.flush() - # assert the first one retreives the same from the identity map + # assert the first one retrieves the same from the identity map nu = session.query(m).get(u.id) assert u is nu @@ -1430,7 +1430,7 @@ class SaveTest(_fixtures.FixtureTest): mapper(Order, orders, properties={ 'description': sa.orm.deferred(orders.c.description)}) - # dont set deferred attribute, commit session + # don't set deferred attribute, commit session o = Order(id=42) session = create_session(autocommit=False) session.add(o) diff --git a/test/orm/test_versioning.py b/test/orm/test_versioning.py index a7e6636ab..7a6dc106e 100644 --- a/test/orm/test_versioning.py +++ b/test/orm/test_versioning.py @@ -90,7 +90,7 @@ class VersioningTest(fixtures.MappedTest): else: s1.commit() - # new in 0.5 ! dont need to close the session + # new in 0.5 ! don't need to close the session f1 = s1.query(Foo).get(f1.id) f2 = s1.query(Foo).get(f2.id) |
