Unable to run tests with flow-cli@v0.41.2
mellosti opened this issue · 1 comments
mellosti commented
Problem
I am trying to run my tests after upgrading to flow-cli@v0.41.2. Here is the error:
● getNFTs › get all NFTs from account
thrown: "Exceeded timeout of 30000 ms for a hook.
Use jest.setTimeout(newTimeout) to increase the timeout value, if this is a long-running test."
11 | describe("getNFTs", () => {
12 | // Instantiate emulator and path to Cadence files
> 13 | beforeEach(async () => {
| ^
14 | const basePath = path.resolve(__dirname, "../../../");
15 | const port = 7003;
16 | await init(basePath, { port });
at test/shared/getNFTs.test.ts:13:2
at Object.<anonymous> (test/shared/getNFTs.test.ts:11:1)
Setting logging: true, does not log anything. I have downgraded back to v.0.39.3 to make it work.
Steps to Reproduce
- Install flow-cli:
sh -ci "$(curl -fsSL https://storage.googleapis.com/flow-cli/install.sh)" -- v0.41.2
- Run any test using this library with jest
Context
I want to use flow-cli v0.41.2 with latest features, but I am not able to test my scripts using this library.
mellosty commented
I built flow-js-testing locally, changed the code so it logs to everything and ran it in my tests. Getting following error:
console.error
Access Node Error
============================
The provided access node http://localhost:60232 does not appear to be a valid REST/HTTP access node.
Please verify that you are not unintentionally using a GRPC access node.
See more here: https://docs.onflow.org/fcl/reference/sdk-guidelines/#connect
I don't understand why. Getting data on http://localhost:60232/v1/blocks?height=final and I have upgraded fcl.