@@ -28,6 +28,11 @@ describe('FFI Error Code Preservation', () => {
2828 raw : csColumn ( 'raw' ) ,
2929 } )
3030
31+ // Schema with non-existent column for triggering FFI UNKNOWN_COLUMN error
32+ const badModelSchema = csTable ( 'test_table' , {
33+ nonexistent : csColumn ( 'nonexistent_column' ) ,
34+ } )
35+
3136 beforeAll ( async ( ) => {
3237 protectClient = await protect ( { schemas : [ testSchema , noIndexSchema ] } )
3338 } )
@@ -203,11 +208,6 @@ describe('FFI Error Code Preservation', () => {
203208 } )
204209
205210 describe ( 'encryptModel error codes' , ( ) => {
206- // Schema with non-existent column for triggering FFI error
207- const badModelSchema = csTable ( 'test_table' , {
208- nonexistent : csColumn ( 'nonexistent_column' ) ,
209- } )
210-
211211 it ( 'returns UNKNOWN_COLUMN code for model with non-existent column' , async ( ) => {
212212 const model = { nonexistent : 'test value' }
213213
@@ -238,10 +238,6 @@ describe('FFI Error Code Preservation', () => {
238238 } )
239239
240240 describe ( 'bulkEncryptModels error codes' , ( ) => {
241- const badModelSchema = csTable ( 'test_table' , {
242- nonexistent : csColumn ( 'nonexistent_column' ) ,
243- } )
244-
245241 it ( 'returns UNKNOWN_COLUMN code for models with non-existent column' , async ( ) => {
246242 const models = [ { nonexistent : 'value1' } , { nonexistent : 'value2' } ]
247243
0 commit comments