Skip to content

Commit

Permalink
import fixups in test (remove baseUrl dependence)
Browse files Browse the repository at this point in the history
  • Loading branch information
mixmix committed Jul 31, 2024
1 parent 93e0ae2 commit 56260a0
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
10 changes: 5 additions & 5 deletions tests/manage-accounts.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ import { randomAsHex } from '@polkadot/util-crypto'
import test from 'tape'
// @ts-ignore
import { spinNetworkUp, spinNetworkDown, } from "@entropyxyz/sdk/testing"
import { EntropyAccountConfig, EntropyConfig } from 'src/config/types'
import { listAccounts } from 'src/flows/manage-accounts/list'
import { createAccount } from 'src/flows/manage-accounts/helpers/create-account'
import * as config from 'src/config'
import { EntropyAccountConfig, EntropyConfig } from '../src/config/types'
import { listAccounts } from '../src/flows/manage-accounts/list'
import { createAccount } from '../src/flows/manage-accounts/helpers/create-account'
import * as config from '../src/config'
import { promiseRunner, sleep } from './testing-utils'
import { charlieStashAddress, charlieStashSeed } from './testing-utils/constants'

Expand Down Expand Up @@ -78,4 +78,4 @@ test('Create Account', async t => {
t.ok(isValidAddress, 'Valid address created')
t.equal(newAccount.address, admin.address, 'Generated Account matches Account created by Keyring')
t.end()
})
})
4 changes: 2 additions & 2 deletions tests/register.test.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import test from 'tape'

import { charlieStashSeed, setupTest } from './testing-utils'
import { register } from 'src/flows/register/register'
import { register } from '../src/flows/register/register'
import { readFileSync } from 'node:fs'

const networkType = 'two-nodes'
Expand All @@ -21,7 +21,7 @@ test('Regsiter - Default Program', async (t) => {
test('Register - Barebones Program', async t => {
const { run, entropy } = await setupTest(t, { networkType, seed: charlieStashSeed })
const dummyProgram: any = readFileSync(
'./programs/template_barebones.wasm'
new URL('./programs/template_barebones.wasm', import.meta.url)
)
const pointer = await run(
'deploy program',
Expand Down
6 changes: 3 additions & 3 deletions tests/transfer.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ import {
} from './testing-utils'

import { getBalance } from '../src/flows/balance/balance'
import { initializeEntropy } from 'src/common/initializeEntropy'
import { initializeEntropy } from '../src/common/initializeEntropy'
import { transfer } from '../src/flows/entropyTransfer/transfer'
import { charlieStashAddress, charlieStashSeed } from './testing-utils/constants'
import { transfer } from 'src/flows/entropyTransfer/transfer'

const networkType = 'two-nodes'

Expand Down Expand Up @@ -79,4 +79,4 @@ test('Transfer', async (t) => {
t.equal(naynayBalance, 1000 * 10e10, 'naynay is rolling in it!')

t.end()
})
})

0 comments on commit 56260a0

Please sign in to comment.