(self)
| 2132 | t.append_column(Column("col", String)) |
| 2133 | |
| 2134 | def test_append_column_existing_key(self): |
| 2135 | t = Table("t", MetaData(), Column("col", Integer, key="c2")) |
| 2136 | |
| 2137 | with testing.expect_raises_message( |
| 2138 | exc.DuplicateColumnError, |
| 2139 | r"A column with key 'c2' is already present in table 't'. " |
| 2140 | r"Specify replace_existing=True to Table.append_column\(\) or " |
| 2141 | r"Table.insert_column\(\) to " |
| 2142 | r"replace an existing column.", |
| 2143 | ): |
| 2144 | t.append_column(Column("col", String, key="c2")) |
| 2145 | |
| 2146 | @testing.variation("field", ["name", "key"]) |
| 2147 | def test_append_column_replace_existing(self, field: Variation): |
nothing calls this directly
no test coverage detected