feat: add testing to create-fuels
#12796
Annotations
5 errors
packages/create-fuels/test/utils/bootstrapProject.ts#L57
Error: ENOTEMPTY: directory not empty, rmdir '/home/runner/work/fuels-ts/fuels-ts/packages/create-fuels/templates/nextjs/sway-programs'
❯ Object.rmdirSync node:fs:1222:10
❯ Proxy.rmSync node:fs:1271:10
❯ Module.resetFilesystem packages/create-fuels/test/utils/bootstrapProject.ts:57:5
❯ packages/create-fuels/test/cli.test.ts:33:5
⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯
Serialized Error: { errno: -39, syscall: 'rmdir', code: 'ENOTEMPTY', path: '/home/runner/work/fuels-ts/fuels-ts/packages/create-fuels/templates/nextjs/sway-programs' }
|
packages/create-fuels/src/lib/rewriteTemplateFiles.ts#L13
Error: ENOENT: no such file or directory, open '/home/runner/work/fuels-ts/fuels-ts/packages/create-fuels/templates/nextjs/package.json'
❯ Object.openSync node:fs:596:3
❯ Proxy.readFileSync node:fs:464:35
❯ Module.rewriteTemplateFiles packages/create-fuels/src/lib/rewriteTemplateFiles.ts:13:17
❯ Module.copyTemplate packages/create-fuels/test/utils/bootstrapProject.ts:51:5
❯ packages/create-fuels/test/cli.test.ts:28:5
⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯
Serialized Error: { errno: -2, syscall: 'open', code: 'ENOENT', path: '/home/runner/work/fuels-ts/fuels-ts/packages/create-fuels/templates/nextjs/package.json' }
|
packages/fuel-gauge/src/token-test-contract.test.ts#L159
AssertionError: expected '0x64' to deeply equal '0x32'
- Expected
+ Received
- 0x32
+ 0x64
❯ packages/fuel-gauge/src/token-test-contract.test.ts:159:42
|
packages/create-fuels/src/lib/rewriteTemplateFiles.test.ts#L48
AssertionError: expected '{\n "name": "template-nextjs",\n "v…' to contain '"fuels": "^0.0.0"'
- Expected
+ Received
- "fuels": "^0.0.0"
+ {
+ "name": "template-nextjs",
+ "version": "0.1.3",
+ "private": true,
+ "scripts": {
+ "prebuild": "fuels build",
+ "fuels:dev": "fuels dev",
+ "dev": "next dev",
+ "build": "pnpm run prebuild && next build",
+ "start": "next start",
+ "lint": "next lint",
+ "test": "vitest"
+ },
+ "dependencies": {
+ "@fuels/connectors": "^0.8.1",
+ "@fuels/react": "^0.20.0",
+ "fuels": "0.92.0",
+ "@tanstack/react-query": "^5.29.2",
+ "dotenv": "^16.4.5",
+ "next": "14.2.4",
+ "react": "^18.3",
+ "react-dom": "^18.3",
+ "react-hot-toast": "^2.4.1",
+ "react-use": "^17.5.0"
+ },
+ "devDependencies": {
+ "@types/node": "^20",
+ "@types/react": "^18.3",
+ "@types/react-dom": "^18.3",
+ "autoprefixer": "^10.4.19",
+ "eslint": "^8",
+ "eslint-config-next": "14.2.4",
+ "postcss": "^8",
+ "tailwindcss": "^3.4.4",
+ "typescript": "~5.4.5",
+ "vitest": "^1.6.0"
+ }
+ }
+
❯ packages/create-fuels/src/lib/rewriteTemplateFiles.test.ts:48:25
|
|
This job failed
Loading