From e66c9d47f2bb2b79c2395ea06c72b1cc633c9cf1 Mon Sep 17 00:00:00 2001 From: coldstar1993 Date: Sun, 10 Mar 2024 06:25:38 +0800 Subject: [PATCH] add js suffix when import --- test/compact_smt.test.ts | 8 ++++---- test/level_store.test.ts | 2 +- test/memory_store.test.ts | 2 +- test/merkle_tree.test.ts | 8 ++++---- test/mongo_store.test.ts | 2 +- test/rocks_store.test.ts | 2 +- test/smt.test.ts | 8 ++++---- 7 files changed, 16 insertions(+), 16 deletions(-) diff --git a/test/compact_smt.test.ts b/test/compact_smt.test.ts index f30858f..e26fd97 100644 --- a/test/compact_smt.test.ts +++ b/test/compact_smt.test.ts @@ -1,8 +1,8 @@ import { Field, Poseidon, Provable } from 'o1js'; -import { CSMTUtils } from '../src/lib/compact_smt/proofs'; -import { CompactSparseMerkleTree } from '../src/lib/compact_smt/csmt'; -import { ProvableCSMTUtils } from '../src/lib/compact_smt/verify_circuit'; -import { MemoryStore } from '../src/lib/store/memory_store'; +import { CSMTUtils } from '../src/lib/compact_smt/proofs.js'; +import { CompactSparseMerkleTree } from '../src/lib/compact_smt/csmt.js'; +import { ProvableCSMTUtils } from '../src/lib/compact_smt/verify_circuit.js'; +import { MemoryStore } from '../src/lib/store/memory_store.js'; describe('CompactSparseMerkleTree', () => { let tree: CompactSparseMerkleTree; diff --git a/test/level_store.test.ts b/test/level_store.test.ts index 6b14826..a05c5a5 100644 --- a/test/level_store.test.ts +++ b/test/level_store.test.ts @@ -1,6 +1,6 @@ import { Level } from 'level'; import { Field } from 'o1js'; -import { LevelStore } from '../src/lib/store/level_store'; +import { LevelStore } from '../src/lib/store/level_store.js'; import { jest } from '@jest/globals'; jest.setTimeout(100000); diff --git a/test/memory_store.test.ts b/test/memory_store.test.ts index 8bc7457..c5b761e 100644 --- a/test/memory_store.test.ts +++ b/test/memory_store.test.ts @@ -1,5 +1,5 @@ import { Field } from 'o1js'; -import { MemoryStore } from '../src/lib/store/memory_store'; +import { MemoryStore } from '../src/lib/store/memory_store.js'; describe('MemoryStore', () => { let store: MemoryStore; diff --git a/test/merkle_tree.test.ts b/test/merkle_tree.test.ts index 63c5a7e..83aa8e6 100644 --- a/test/merkle_tree.test.ts +++ b/test/merkle_tree.test.ts @@ -1,8 +1,8 @@ import { Field, Provable } from 'o1js'; -import { MerkleTree } from '../src/lib/merkle/merkle_tree'; -import { MerkleTreeUtils } from '../src/lib/merkle/proofs'; -import { ProvableMerkleTreeUtils } from '../src/lib/merkle/verify_circuit'; -import { MemoryStore } from '../src/lib/store/memory_store'; +import { MerkleTree } from '../src/lib/merkle/merkle_tree.js'; +import { MerkleTreeUtils } from '../src/lib/merkle/proofs.js'; +import { ProvableMerkleTreeUtils } from '../src/lib/merkle/verify_circuit.js'; +import { MemoryStore } from '../src/lib/store/memory_store.js'; describe('SparseMerkleTree', () => { let tree: MerkleTree; diff --git a/test/mongo_store.test.ts b/test/mongo_store.test.ts index 559d4c7..e7b7b6c 100644 --- a/test/mongo_store.test.ts +++ b/test/mongo_store.test.ts @@ -1,6 +1,6 @@ import mongoose from 'mongoose'; import { Field } from 'o1js'; -import { MongoStore } from '../src/lib/store/mongo_store'; +import { MongoStore } from '../src/lib/store/mongo_store.js'; import { MongoMemoryReplSet } from 'mongodb-memory-server'; import { jest } from '@jest/globals'; diff --git a/test/rocks_store.test.ts b/test/rocks_store.test.ts index 16c02b6..ef86840 100644 --- a/test/rocks_store.test.ts +++ b/test/rocks_store.test.ts @@ -1,5 +1,5 @@ import { Field } from 'o1js'; -import { RocksStore } from '../src/lib/store/rocks_store'; +import { RocksStore } from '../src/lib/store/rocks_store.js'; import encode from 'encoding-down'; import rocksdb from 'rocksdb'; import levelup from 'levelup'; diff --git a/test/smt.test.ts b/test/smt.test.ts index 8215101..125cf3d 100644 --- a/test/smt.test.ts +++ b/test/smt.test.ts @@ -1,8 +1,8 @@ import { Field, Poseidon, Provable } from 'o1js'; -import { MemoryStore } from '../src/lib/store/memory_store'; -import { SparseMerkleTree } from '../src/lib/smt/smt'; -import { SMTUtils } from '../src/lib/smt/proofs'; -import { ProvableSMTUtils } from '../src/lib/smt/verify_circuit'; +import { MemoryStore } from '../src/lib/store/memory_store.js'; +import { SparseMerkleTree } from '../src/lib/smt/smt.js'; +import { SMTUtils } from '../src/lib/smt/proofs.js'; +import { ProvableSMTUtils } from '../src/lib/smt/verify_circuit.js'; describe('SparseMerkleTree', () => { let tree: SparseMerkleTree;