DBT tests don't work on an iceberg table on Glue

The problem I’m having is the data tests fails while running on an iceberg table on AWS Glue

What I’ve already tried is changing the target schema to glue_catalog.my_schema_name this made the test work but not a valid solution as dbt creates two schemas one with glue_catalog. and the other without it.

Some example code or error messages

When the test runs it compiles to this sql:

  select c1
  from (select * from my_schema.my_ice_table) dbt_subquery
  where c1 is null

I know that to access any iceberg table in glue you have to have the prefix glue_catalog

 AnalysisException: org.apache.hadoop.hive.ql.metadata.HiveException: Unable to fetch table my_ice_table. StorageDescriptor#InputFormat cannot be null for table: my_ice_table