diff --git a/plugin/trino-snowflake/src/test/java/io/trino/plugin/snowflake/TestSnowflakeConnectorTest.java b/plugin/trino-snowflake/src/test/java/io/trino/plugin/snowflake/TestSnowflakeConnectorTest.java index 9ff18a1771a9..48095992c240 100644 --- a/plugin/trino-snowflake/src/test/java/io/trino/plugin/snowflake/TestSnowflakeConnectorTest.java +++ b/plugin/trino-snowflake/src/test/java/io/trino/plugin/snowflake/TestSnowflakeConnectorTest.java @@ -189,13 +189,10 @@ public void testShowCreateTable() ")"); } - @Test @Override - public void testAddNotNullColumn() + protected void verifyAddNotNullColumnToNonEmptyTableFailurePermissible(Throwable e) { - assertThatThrownBy(super::testAddNotNullColumn) - .isInstanceOf(AssertionError.class) - .hasMessage("Unexpected failure when adding not null column"); + assertThat(e).hasMessageMatching("SQL compilation error: Non-nullable column .* cannot be added to non-empty table .* unless it has a non-null default value."); } @Test