@@ -316,7 +316,7 @@ describe('Private Execution test suite', () => {
316
316
317
317
expect ( result . newNotes ) . toHaveLength ( 1 ) ;
318
318
const newNote = result . newNotes [ 0 ] ;
319
- expect ( newNote . storageSlot ) . toEqual ( computeSlotForMapping ( new Fr ( 1n ) , owner . toField ( ) ) ) ;
319
+ expect ( newNote . storageSlot ) . toEqual ( computeSlotForMapping ( new Fr ( 1n ) , owner ) ) ;
320
320
321
321
const newCommitments = sideEffectArrayToValueArray (
322
322
nonEmptySideEffects ( result . callStackItem . publicInputs . newCommitments ) ,
@@ -336,7 +336,7 @@ describe('Private Execution test suite', () => {
336
336
337
337
expect ( result . newNotes ) . toHaveLength ( 1 ) ;
338
338
const newNote = result . newNotes [ 0 ] ;
339
- expect ( newNote . storageSlot ) . toEqual ( computeSlotForMapping ( new Fr ( 1n ) , owner . toField ( ) ) ) ;
339
+ expect ( newNote . storageSlot ) . toEqual ( computeSlotForMapping ( new Fr ( 1n ) , owner ) ) ;
340
340
341
341
const newCommitments = sideEffectArrayToValueArray (
342
342
nonEmptySideEffects ( result . callStackItem . publicInputs . newCommitments ) ,
@@ -353,8 +353,8 @@ describe('Private Execution test suite', () => {
353
353
const amountToTransfer = 100n ;
354
354
const artifact = getFunctionArtifact ( StatefulTestContractArtifact , 'destroy_and_create' ) ;
355
355
356
- const storageSlot = computeSlotForMapping ( new Fr ( 1n ) , owner . toField ( ) ) ;
357
- const recipientStorageSlot = computeSlotForMapping ( new Fr ( 1n ) , recipient . toField ( ) ) ;
356
+ const storageSlot = computeSlotForMapping ( new Fr ( 1n ) , owner ) ;
357
+ const recipientStorageSlot = computeSlotForMapping ( new Fr ( 1n ) , recipient ) ;
358
358
359
359
const notes = [ buildNote ( 60n , owner , storageSlot ) , buildNote ( 80n , owner , storageSlot ) ] ;
360
360
oracle . getNotes . mockResolvedValue ( notes ) ;
@@ -407,7 +407,7 @@ describe('Private Execution test suite', () => {
407
407
const balance = 160n ;
408
408
const artifact = getFunctionArtifact ( StatefulTestContractArtifact , 'destroy_and_create' ) ;
409
409
410
- const storageSlot = computeSlotForMapping ( new Fr ( 1n ) , owner . toField ( ) ) ;
410
+ const storageSlot = computeSlotForMapping ( new Fr ( 1n ) , owner ) ;
411
411
412
412
const notes = [ buildNote ( balance , owner , storageSlot ) ] ;
413
413
oracle . getNotes . mockResolvedValue ( notes ) ;
@@ -905,7 +905,7 @@ describe('Private Execution test suite', () => {
905
905
906
906
expect ( result . newNotes ) . toHaveLength ( 1 ) ;
907
907
const noteAndSlot = result . newNotes [ 0 ] ;
908
- expect ( noteAndSlot . storageSlot ) . toEqual ( computeSlotForMapping ( new Fr ( 1n ) , owner . toField ( ) ) ) ;
908
+ expect ( noteAndSlot . storageSlot ) . toEqual ( computeSlotForMapping ( new Fr ( 1n ) , owner ) ) ;
909
909
910
910
expect ( noteAndSlot . note . items [ 0 ] ) . toEqual ( new Fr ( amountToTransfer ) ) ;
911
911
@@ -915,7 +915,7 @@ describe('Private Execution test suite', () => {
915
915
expect ( newCommitments ) . toHaveLength ( 1 ) ;
916
916
917
917
const commitment = newCommitments [ 0 ] ;
918
- const storageSlot = computeSlotForMapping ( new Fr ( 1n ) , owner . toField ( ) ) ;
918
+ const storageSlot = computeSlotForMapping ( new Fr ( 1n ) , owner ) ;
919
919
const innerNoteHash = await acirSimulator . computeInnerNoteHash ( contractAddress , storageSlot , noteAndSlot . note ) ;
920
920
expect ( commitment ) . toEqual ( innerNoteHash ) ;
921
921
@@ -986,7 +986,7 @@ describe('Private Execution test suite', () => {
986
986
987
987
expect ( execInsert . newNotes ) . toHaveLength ( 1 ) ;
988
988
const noteAndSlot = execInsert . newNotes [ 0 ] ;
989
- expect ( noteAndSlot . storageSlot ) . toEqual ( computeSlotForMapping ( new Fr ( 1n ) , owner . toField ( ) ) ) ;
989
+ expect ( noteAndSlot . storageSlot ) . toEqual ( computeSlotForMapping ( new Fr ( 1n ) , owner ) ) ;
990
990
991
991
expect ( noteAndSlot . note . items [ 0 ] ) . toEqual ( new Fr ( amountToTransfer ) ) ;
992
992
@@ -996,7 +996,7 @@ describe('Private Execution test suite', () => {
996
996
expect ( newCommitments ) . toHaveLength ( 1 ) ;
997
997
998
998
const commitment = newCommitments [ 0 ] ;
999
- const storageSlot = computeSlotForMapping ( new Fr ( 1n ) , owner . toField ( ) ) ;
999
+ const storageSlot = computeSlotForMapping ( new Fr ( 1n ) , owner ) ;
1000
1000
const innerNoteHash = await acirSimulator . computeInnerNoteHash ( contractAddress , storageSlot , noteAndSlot . note ) ;
1001
1001
expect ( commitment ) . toEqual ( innerNoteHash ) ;
1002
1002
@@ -1042,7 +1042,7 @@ describe('Private Execution test suite', () => {
1042
1042
1043
1043
expect ( result . newNotes ) . toHaveLength ( 1 ) ;
1044
1044
const noteAndSlot = result . newNotes [ 0 ] ;
1045
- expect ( noteAndSlot . storageSlot ) . toEqual ( computeSlotForMapping ( new Fr ( 1n ) , owner . toField ( ) ) ) ;
1045
+ expect ( noteAndSlot . storageSlot ) . toEqual ( computeSlotForMapping ( new Fr ( 1n ) , owner ) ) ;
1046
1046
1047
1047
expect ( noteAndSlot . note . items [ 0 ] ) . toEqual ( new Fr ( amountToTransfer ) ) ;
1048
1048
@@ -1052,7 +1052,7 @@ describe('Private Execution test suite', () => {
1052
1052
expect ( newCommitments ) . toHaveLength ( 1 ) ;
1053
1053
1054
1054
const commitment = newCommitments [ 0 ] ;
1055
- const storageSlot = computeSlotForMapping ( new Fr ( 1n ) , owner . toField ( ) ) ;
1055
+ const storageSlot = computeSlotForMapping ( new Fr ( 1n ) , owner ) ;
1056
1056
expect ( commitment ) . toEqual (
1057
1057
await acirSimulator . computeInnerNoteHash ( contractAddress , storageSlot , noteAndSlot . note ) ,
1058
1058
) ;
0 commit comments