(self, assert_on)
| 1140 | argnames=class="st">"assert_on", |
| 1141 | ) |
| 1142 | def test_cache_key_gen(self, assert_on): |
| 1143 | Employee = self.classes.Employee |
| 1144 | |
| 1145 | e1 = aliased(Employee) |
| 1146 | e2 = aliased(Employee) |
| 1147 | |
| 1148 | subq = select(e1).union_all(select(e2)).subquery() |
| 1149 | |
| 1150 | anno = aliased(Employee, subq) |
| 1151 | |
| 1152 | stmt = select(anno) |
| 1153 | |
| 1154 | ck = stmt._generate_cache_key() |
| 1155 | |
| 1156 | if assert_on == class="st">"tuples": |
| 1157 | class="cm"># before the fix for #8790 this was 700 |
| 1158 | int_within_variance(142, count_cache_key_tuples(ck), 0.05) |
| 1159 | |
| 1160 | elif assert_on == class="st">"memory": |
| 1161 | class="cm"># before the fix for #8790 this was 55154 |
| 1162 | |
| 1163 | if util.py312: |
| 1164 | testing.skip_test(class="st">"python platform not available") |
| 1165 | elif util.py311: |
| 1166 | int_within_variance(39996, total_size(ck), 0.05) |
| 1167 | else: |
| 1168 | int_within_variance(29796, total_size(ck), 0.05) |
| 1169 | |
| 1170 | |
| 1171 | class WithExpresionLoaderOptTest(DeclarativeMappedTest): |
nothing calls this directly
no test coverage detected