diff options
| author | mike bayer <mike_mp@zzzcomputing.com> | 2017-09-09 10:28:56 -0400 |
|---|---|---|
| committer | Gerrit Code Review <gerrit@awstats.zzzcomputing.com> | 2017-09-09 10:28:56 -0400 |
| commit | ca2c42df6ba108289031ccecd030b7aa196a66d6 (patch) | |
| tree | 9282049318ff24d18b708e9971f6316554fc0fa9 /test | |
| parent | 70be7312f10a2241cde3e6472af15ef5a9ae222a (diff) | |
| parent | e83024d3fa45973d4dc1809282588dda8ac9bfce (diff) | |
| download | sqlalchemy-ca2c42df6ba108289031ccecd030b7aa196a66d6.tar.gz | |
Merge "Remove LRU warnings"
Diffstat (limited to 'test')
| -rw-r--r-- | test/orm/test_mapper.py | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/test/orm/test_mapper.py b/test/orm/test_mapper.py index f39e174b0..42d114f6f 100644 --- a/test/orm/test_mapper.py +++ b/test/orm/test_mapper.py @@ -262,31 +262,6 @@ class MapperTest(_fixtures.FixtureTest, AssertsCompiledSQL): assert_raises(TypeError, Foo, x=5) assert_raises(TypeError, Bar, x=5) - def test_lru_cache_warning(self): - users = self.tables.users - User = self.classes.User - m = mapper(User, users) - - for i in range(149): - m._compiled_cache["key_%s" % i] = "foo" - - def go(): - m._compiled_cache["key_150"] = "foo" - m._compiled_cache["key_151"] = "foo" - - assert_raises_message( - sa.exc.SAWarning, - r"Compiled statement cache for mapper Mapper.User.users is " - "reaching its size threshold of 150, based on " - "_compiled_cache_size of 100. ", - go - ) - m._compiled_cache.size_alert = None - for i in range(152, 200): - m._compiled_cache["key_%d" % i] = "foo" - assert len(m._compiled_cache) < 150 - - def test_sort_states_comparisons(self): """test that _sort_states() doesn't compare insert_order to state.key, for set of mixed |
