tact-lang / tact-emulator

@tact-lang/emulator testing library
MIT License
23 stars 8 forks source link

Tests fail for emulator TON v2024.04 #13

Open 0kenx opened 4 weeks ago

0kenx commented 4 weeks ago

Tests fail for emulator TON v2024.04, TON v2024.03 and TON v2024.02 versions.

$ jest --verbose --runInBand
 FAIL  src/emulator/ContractExecutor.spec.ts
  ContractExecutor
    ✕ should execute simple get methods (48 ms)

  ● ContractExecutor › should execute simple get methods

    memory access out of bounds

      275 |             return module[name](...mappedArgs);
      276 |         } catch (e) {
    > 277 |             throw Error((e as any).message);
          |                   ^
      278 |         } finally {
      279 |             allocatedPointers.forEach((pointer) => module._free(pointer));
      280 |         }

      at EmulatorBindings.invoke (src/bindings/EmulatorBindings.ts:277:19)
      at src/bindings/EmulatorBindings.ts:210:32

  console.log
    [ 4][t 0][2024-06-09 08:37:07.938000][mc-config.cpp:260]    needSpecialSmc flag set

      at _emscripten_log_js (src/bindings/wasm/emulator-emscripten.js:9:28972)

  console.log
    [ 4][t 0][2024-06-09 08:37:07.954000][mc-config.cpp:266]    smc dictionary created

      at _emscripten_log_js (src/bindings/wasm/emulator-emscripten.js:9:28972)

  console.log
    [ 4][t 0][2024-06-09 08:37:07.956000][mc-config.cpp:469]    workchain description dictionary created

      at _emscripten_log_js (src/bindings/wasm/emulator-emscripten.js:9:28972)

  console.log
    [ 4][t 0][2024-06-09 08:37:07.957000][mc-config.cpp:2129]   unpacked info for workchain 0: basic=true, active=true, accept_msgs=true, min_split=1, max_split=32

      at _emscripten_log_js (src/bindings/wasm/emulator-emscripten.js:9:28972)

  console.warn
    ===================
    TX: 0
    ===================
    === VM LOGS ===
    execute SETCP 0
    execute DICTPUSHCONST 19 (xC_,1)
    execute DICTIGETJMPZ
    execute PUSHPOW2 9
{redacted}
      33 |         // Events
      34 |         expect(tracker.collect()).toMatchSnapshot();
    > 35 |         console.warn(logs.collect());
         |                 ^
      36 |     });
      37 | });

      at Object.<anonymous> (src/emulator/ContractSystem.spec.ts:35:17)
Test Suites: 1 failed, 2 passed, 3 total
Tests:       1 failed, 3 passed, 4 total
Snapshots:   2 passed, 2 total
Time:        1.664 s, estimated 7 s
Ran all test suites.
error Command failed with exit code 1.