lint: lint fixes

This commit is contained in:
ppe
2022-05-10 21:48:51 +02:00
parent c2061e56be
commit f00c7cb683
3 changed files with 22 additions and 8 deletions

View File

@@ -108,11 +108,15 @@ describe('Testing the SmartWeave client', () => {
});
it('should properly read state with a fresh client', async () => {
const contract2 = SmartWeaveNodeFactory.fileCachedBased(arweave, cacheDir).useArweaveGateway().build()
const contract2 = SmartWeaveNodeFactory.fileCachedBased(arweave, cacheDir)
.useArweaveGateway()
.build()
.contract<ExampleContractState>(contract.txId())
.connect(wallet);
const contract2VM = SmartWeaveNodeFactory.fileCachedBased(arweave, cacheDir).useArweaveGateway().build()
const contract2VM = SmartWeaveNodeFactory.fileCachedBased(arweave, cacheDir)
.useArweaveGateway()
.build()
.contract<ExampleContractState>(contract.txId())
.connect(wallet);
expect((await contract2.readState()).state.counter).toEqual(559);
@@ -127,10 +131,14 @@ describe('Testing the SmartWeave client', () => {
});
it('should properly read state with another fresh client', async () => {
const contract3 = SmartWeaveNodeFactory.fileCachedBased(arweave, cacheDir).useArweaveGateway().build()
const contract3 = SmartWeaveNodeFactory.fileCachedBased(arweave, cacheDir)
.useArweaveGateway()
.build()
.contract<ExampleContractState>(contract.txId())
.connect(wallet);
const contract3VM = SmartWeaveNodeFactory.fileCachedBased(arweave, cacheDir).useArweaveGateway().build()
const contract3VM = SmartWeaveNodeFactory.fileCachedBased(arweave, cacheDir)
.useArweaveGateway()
.build()
.contract<ExampleContractState>(contract.txId())
.setEvaluationOptions({
useVM2: true
@@ -153,10 +161,14 @@ describe('Testing the SmartWeave client', () => {
await contract.writeInteraction({ function: 'add' });
await mineBlock(arweave);
const contract4 = SmartWeaveNodeFactory.fileCachedBased(arweave, cacheDir).useArweaveGateway().build()
const contract4 = SmartWeaveNodeFactory.fileCachedBased(arweave, cacheDir)
.useArweaveGateway()
.build()
.contract<ExampleContractState>(contract.txId())
.connect(wallet);
const contract4VM = SmartWeaveNodeFactory.fileCachedBased(arweave, cacheDir).useArweaveGateway().build()
const contract4VM = SmartWeaveNodeFactory.fileCachedBased(arweave, cacheDir)
.useArweaveGateway()
.build()
.contract<ExampleContractState>(contract.txId())
.setEvaluationOptions({
useVM2: true

View File

@@ -2,7 +2,8 @@ import Arweave from 'arweave';
import {
ArweaveGatewayInteractionsLoader,
CacheableContractInteractionsLoader,
ConfirmationStatus, ContractDefinitionLoader,
ConfirmationStatus,
ContractDefinitionLoader,
DebuggableExecutorFactory,
DefinitionLoader,
ExecutorFactory,

View File

@@ -1,7 +1,8 @@
import Arweave from 'arweave';
import {
ArweaveGatewayInteractionsLoader,
CacheableStateEvaluator, ConfirmationStatus,
CacheableStateEvaluator,
ConfirmationStatus,
ContractDefinitionLoader,
HandlerExecutorFactory,
LexicographicalInteractionsSorter,