@@ -85,9 +85,7 @@ describe('integration', () => {
8585 expectVerifierToBe ( newVerifier ) ;
8686 } ) ;
8787
88- it . skip ( 'sudo_can_steal_tokens' , async ( ) => {
89- throw new Error ( 'Not implemented' ) ;
90- } ) ;
88+ it . skip ( 'sudo_can_steal_tokens' , async ( ) => { } ) ; // sudo not implemented
9189
9290 it . skip ( 'querier_callbacks_work' , async ( ) => { // query_chain not implemented
9391 // Arrange
@@ -101,7 +99,7 @@ describe('integration', () => {
10199
102100 // Assert
103101 expectResponseToBeOk ( queryResponse ) ;
104- // ToDo: more asserts
102+ // ToDo: moar assert
105103 } ) ;
106104
107105 it ( 'fails_on_bad_init' , async ( ) => {
@@ -130,27 +128,30 @@ describe('integration', () => {
130128
131129 // Assert
132130 expectResponseToBeOk ( execResponse ) ;
133- // ToDo: more asserts
131+ // ToDo: moar assert
134132 } ) ;
135133
136- it ( 'execute_release_fails_for_wrong_sender' , async ( ) => { } ) ;
137-
138- it ( 'execute_argon2' , async ( ) => { } ) ;
139-
140- it ( 'execute_cpu_loop' , async ( ) => { } ) ;
134+ it . skip ( 'execute_release_fails_for_wrong_sender' , async ( ) => { } ) ; // query_chain not implemented
141135
142- it ( 'execute_storage_loop ' , async ( ) => { } ) ;
143-
144- it ( 'execute_memory_loop' , async ( ) => { } ) ;
136+ it ( 'execute_panic ' , async ( ) => {
137+ // Arrange
138+ vm . instantiate ( mockEnv , mockInfo , { verifier , beneficiary } ) ;
145139
146- it ( 'execute_allocate_large_memory' , async ( ) => { } ) ;
140+ // Act
141+ expect ( ( ) => vm . execute ( mockEnv , mockInfo , { panic : { } } ) ) . toThrow ( ) ;
142+ } ) ;
147143
148- it ( 'execute_panic' , async ( ) => { } ) ;
144+ it ( 'execute_user_errors_in_api_calls' , async ( ) => {
145+ // Arrange
146+ vm . instantiate ( mockEnv , mockInfo , { verifier, beneficiary } ) ;
149147
150- it ( 'execute_user_errors_in_api_calls' , async ( ) => { } ) ;
148+ // Act
149+ expect ( ( ) => vm . execute ( mockEnv , mockInfo , { user_errors_in_api_calls : { } } ) ) . toThrow ( ) ;
150+ } ) ;
151151
152152 it . skip ( 'passes_io_tests' , async ( ) => {
153- throw new Error ( 'Not implemented' ) ;
153+ // Reference implementation: https://github.com/CosmWasm/cosmwasm/blob/a9ae6fa76ba6c05de1792f887a09401856f14bc1/packages/vm/src/testing/instance.rs#L171
154+ // pub fn test_io<A, S, Q>(instance: &mut Instance<A, S, Q>)
154155 } ) ;
155156} ) ;
156157
0 commit comments