testeranto 0.219.16 → 0.219.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundle.js +3 -2
- package/dist/prebuild/testeranto.mjs +5 -6
- package/package.json +19 -18
- package/src/Types.ts +12 -170
- package/src/lib/tiposkripto/bundle.js +26 -0
- package/src/lib/tiposkripto/cjs-shim.js +14 -0
- package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/src}/BaseTiposkripto.js +8 -7
- package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/src}/Node.js +4 -4
- package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/src}/Web.js +2 -2
- package/src/lib/tiposkripto/dist/common/lib/tiposkripto/src/index.mjs +48 -0
- package/src/lib/tiposkripto/dist/common/lib/tiposkripto/src/types.js +6 -0
- package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/tests}/abstractBase.test/index.js +1 -1
- package/src/lib/tiposkripto/dist/common/package.json +3 -0
- package/src/lib/tiposkripto/dist/common/tsconfig.common.tsbuildinfo +1 -0
- package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/src}/BaseTiposkripto.js +4 -3
- package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/src}/Node.js +3 -3
- package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/src}/Web.js +3 -3
- package/src/lib/tiposkripto/dist/module/lib/tiposkripto/src/index.mjs +47 -0
- package/src/lib/tiposkripto/dist/module/lib/tiposkripto/src/types.js +3 -0
- package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/tests}/abstractBase.test/index.js +1 -1
- package/src/lib/tiposkripto/dist/module/package.json +3 -0
- package/src/lib/tiposkripto/dist/module/tsconfig.module.tsbuildinfo +1 -0
- package/src/lib/tiposkripto/dist/prebuild/Node-KZP3KCHY.mjs +53 -0
- package/src/lib/tiposkripto/dist/prebuild/Web-N3U4GGVG.mjs +77 -0
- package/src/lib/tiposkripto/dist/prebuild/chunk-IWCYUFDQ.mjs +539 -0
- package/src/lib/tiposkripto/dist/prebuild/chunk-MABQI2BP.mjs +57 -0
- package/src/lib/tiposkripto/dist/prebuild/index.mjs +10 -0
- package/{dist → src/lib/tiposkripto/dist}/types/Types.d.ts +11 -35
- package/{dist/types/lib/tiposkripto → src/lib/tiposkripto/dist/types/lib/tiposkripto/src}/BaseGiven.d.ts +2 -2
- package/{dist/types/lib/tiposkripto → src/lib/tiposkripto/dist/types/lib/tiposkripto/src}/BaseSuite.d.ts +2 -2
- package/{dist/types/lib/tiposkripto → src/lib/tiposkripto/dist/types/lib/tiposkripto/src}/BaseThen.d.ts +2 -2
- package/{dist/types/lib/tiposkripto → src/lib/tiposkripto/dist/types/lib/tiposkripto/src}/BaseTiposkripto.d.ts +4 -4
- package/{dist/types/lib/tiposkripto → src/lib/tiposkripto/dist/types/lib/tiposkripto/src}/BaseWhen.d.ts +1 -1
- package/{dist/types/lib/tiposkripto → src/lib/tiposkripto/dist/types/lib/tiposkripto/src}/CoreTypes.d.ts +7 -3
- package/{dist/types/lib/tiposkripto → src/lib/tiposkripto/dist/types/lib/tiposkripto/src}/Node.d.ts +5 -5
- package/{dist/types/lib/tiposkripto → src/lib/tiposkripto/dist/types/lib/tiposkripto/src}/Web.d.ts +4 -4
- package/{dist/types/lib/tiposkripto/Tiposkripto.d.ts → src/lib/tiposkripto/dist/types/lib/tiposkripto/src/index.d.mts} +5 -2
- package/{dist/types/lib/tiposkripto/index.d.ts → src/lib/tiposkripto/dist/types/lib/tiposkripto/src/types.d.ts} +8 -4
- package/src/lib/tiposkripto/dist/types/tsconfig.types.tsbuildinfo +1 -0
- package/src/lib/tiposkripto/package.json +16 -7
- package/src/lib/tiposkripto/postBuild.sh +11 -0
- package/src/lib/tiposkripto/prebuild.sh +1 -0
- package/src/lib/tiposkripto/{BaseGiven.ts → src/BaseGiven.ts} +2 -2
- package/src/lib/tiposkripto/{BaseSuite.ts → src/BaseSuite.ts} +3 -2
- package/src/lib/tiposkripto/{BaseThen.ts → src/BaseThen.ts} +2 -2
- package/src/lib/tiposkripto/{BaseTiposkripto.ts → src/BaseTiposkripto.ts} +6 -19
- package/src/lib/tiposkripto/{BaseWhen.ts → src/BaseWhen.ts} +1 -1
- package/src/lib/tiposkripto/{CoreTypes.ts → src/CoreTypes.ts} +18 -16
- package/src/lib/tiposkripto/{Node.ts → src/Node.ts} +6 -16
- package/src/lib/tiposkripto/{Web.ts → src/Web.ts} +4 -7
- package/src/lib/tiposkripto/src/index.ts +107 -0
- package/src/lib/tiposkripto/{index.ts → src/types.ts} +20 -44
- package/src/lib/tiposkripto/{abstractBase.test → tests/abstractBase.test}/MockGiven.ts +1 -1
- package/src/lib/tiposkripto/{abstractBase.test → tests/abstractBase.test}/MockThen.ts +1 -1
- package/src/lib/tiposkripto/{abstractBase.test → tests/abstractBase.test}/MockWhen.ts +1 -1
- package/src/lib/tiposkripto/{abstractBase.test → tests/abstractBase.test}/adapter.ts +1 -1
- package/src/lib/tiposkripto/{abstractBase.test → tests/abstractBase.test}/index.ts +1 -1
- package/src/lib/tiposkripto/tsconfig.common.json +45 -0
- package/src/lib/tiposkripto/tsconfig.json +61 -0
- package/src/lib/tiposkripto/tsconfig.module.json +46 -0
- package/src/lib/tiposkripto/tsconfig.types.json +47 -0
- package/src/server/getRunnables.ts +1 -1
- package/src/server/runtimes/node/docker.ts +7 -4
- package/src/server/runtimes/node/esbuild.ts +2 -1
- package/src/server/runtimes/node/node.ts +2 -1
- package/src/server/serverClasees/Server_Docker.ts +3 -3
- package/src/server/types.ts +10 -1
- package/src/testeranto.ts +1 -36
- package/testeranto/docker-compose.yml +1 -201
- package/testeranto/testeranto.ts +60 -60
- package/dist/common/allTestsUtils.js +0 -17
- package/dist/common/scripts/build-example.js +0 -105
- package/dist/common/src/Init.js +0 -38
- package/dist/common/src/Types.js +0 -63
- package/dist/common/src/esbuildConfigs/consoleDetectorPlugin.js +0 -38
- package/dist/common/src/esbuildConfigs/eslint-formatter-testeranto.js +0 -21
- package/dist/common/src/esbuildConfigs/featuresPlugin.js +0 -39
- package/dist/common/src/esbuildConfigs/index.js +0 -22
- package/dist/common/src/esbuildConfigs/inputFilesPlugin.js +0 -30
- package/dist/common/src/esbuildConfigs/nativeImportDetectorPlugin.js +0 -24
- package/dist/common/src/esbuildConfigs/rebuildPlugin.js +0 -19
- package/dist/common/src/init-docs.js +0 -9
- package/dist/common/src/lib/tiposkripto/Tiposkripto.js +0 -49
- package/dist/common/src/lib/tiposkripto/index.js +0 -29
- package/dist/common/src/runtimes.js +0 -4
- package/dist/common/src/server/aider/configParser.js +0 -124
- package/dist/common/src/server/aider/docker.js +0 -30
- package/dist/common/src/server/getRunnables.js +0 -36
- package/dist/common/src/server/htmlTemplate.js +0 -44
- package/dist/common/src/server/nodeVersion.js +0 -5
- package/dist/common/src/server/runtimes/common.js +0 -136
- package/dist/common/src/server/runtimes/golang/docker.js +0 -62
- package/dist/common/src/server/runtimes/java/docker.js +0 -46
- package/dist/common/src/server/runtimes/node/docker.js +0 -42
- package/dist/common/src/server/runtimes/node/esbuild.js +0 -40
- package/dist/common/src/server/runtimes/node/node.js +0 -75
- package/dist/common/src/server/runtimes/python/docker.js +0 -31
- package/dist/common/src/server/runtimes/ruby/docker.js +0 -34
- package/dist/common/src/server/runtimes/rust/docker.js +0 -35
- package/dist/common/src/server/runtimes/web/docker.js +0 -42
- package/dist/common/src/server/runtimes/web/esbuild.js +0 -29
- package/dist/common/src/server/runtimes/web/hoist.js +0 -16
- package/dist/common/src/server/runtimes/web/web.js +0 -157
- package/dist/common/src/server/serverClasees/Server.js +0 -47
- package/dist/common/src/server/serverClasees/Server_Base.js +0 -18
- package/dist/common/src/server/serverClasees/Server_Docker.js +0 -904
- package/dist/common/src/server/serverClasees/Server_FS.js +0 -119
- package/dist/common/src/server/serverClasees/Server_HTTP.js +0 -189
- package/dist/common/src/server/serverClasees/Server_WS.js +0 -262
- package/dist/common/src/server/serverManagers/DockerManager.js +0 -28
- package/dist/common/src/server/serverManagers/HttpManager.js +0 -114
- package/dist/common/src/server/serverManagers/WsManager.js +0 -230
- package/dist/common/src/server/serverManagers/fs.js +0 -32
- package/dist/common/src/server/serverManagers/tcp.js +0 -51
- package/dist/common/src/server/types.js +0 -2
- package/dist/common/src/testeranto.js +0 -75
- package/dist/common/src/vscode/TerminalManager.js +0 -129
- package/dist/common/src/vscode/TestTreeItem.js +0 -77
- package/dist/common/src/vscode/extension.js +0 -185
- package/dist/common/src/vscode/providers/FeaturesTreeDataProvider.js +0 -445
- package/dist/common/src/vscode/providers/FileTreeDataProvider.js +0 -190
- package/dist/common/src/vscode/providers/ProcessesTreeDataProvider.js +0 -270
- package/dist/common/src/vscode/providers/ResultsTreeDataProvider.js +0 -87
- package/dist/common/src/vscode/providers/TestTreeDataProvider.js +0 -309
- package/dist/common/src/vscode/types.js +0 -9
- package/dist/common/testeranto/runtimes/node/node.js +0 -7
- package/dist/common/testeranto/runtimes/web/web.js +0 -6
- package/dist/common/testeranto/testeranto.js +0 -70
- package/dist/common/tsconfig.common.tsbuildinfo +0 -1
- package/dist/module/allTestsUtils.js +0 -13
- package/dist/module/scripts/build-example.js +0 -100
- package/dist/module/src/Init.js +0 -33
- package/dist/module/src/Types.js +0 -62
- package/dist/module/src/esbuildConfigs/consoleDetectorPlugin.js +0 -32
- package/dist/module/src/esbuildConfigs/eslint-formatter-testeranto.js +0 -18
- package/dist/module/src/esbuildConfigs/featuresPlugin.js +0 -34
- package/dist/module/src/esbuildConfigs/index.js +0 -20
- package/dist/module/src/esbuildConfigs/inputFilesPlugin.js +0 -25
- package/dist/module/src/esbuildConfigs/nativeImportDetectorPlugin.js +0 -21
- package/dist/module/src/esbuildConfigs/rebuildPlugin.js +0 -14
- package/dist/module/src/init-docs.js +0 -4
- package/dist/module/src/lib/tiposkripto/Tiposkripto.js +0 -14
- package/dist/module/src/lib/tiposkripto/index.js +0 -24
- package/dist/module/src/runtimes.js +0 -1
- package/dist/module/src/server/aider/configParser.js +0 -116
- package/dist/module/src/server/aider/docker.js +0 -28
- package/dist/module/src/server/getRunnables.js +0 -29
- package/dist/module/src/server/htmlTemplate.js +0 -40
- package/dist/module/src/server/nodeVersion.js +0 -2
- package/dist/module/src/server/runtimes/common.js +0 -127
- package/dist/module/src/server/runtimes/golang/docker.js +0 -55
- package/dist/module/src/server/runtimes/java/docker.js +0 -40
- package/dist/module/src/server/runtimes/node/docker.js +0 -36
- package/dist/module/src/server/runtimes/node/esbuild.js +0 -35
- package/dist/module/src/server/runtimes/node/node.js +0 -37
- package/dist/module/src/server/runtimes/python/docker.js +0 -25
- package/dist/module/src/server/runtimes/ruby/docker.js +0 -28
- package/dist/module/src/server/runtimes/rust/docker.js +0 -29
- package/dist/module/src/server/runtimes/web/docker.js +0 -36
- package/dist/module/src/server/runtimes/web/esbuild.js +0 -24
- package/dist/module/src/server/runtimes/web/hoist.js +0 -11
- package/dist/module/src/server/runtimes/web/web.js +0 -119
- package/dist/module/src/server/serverClasees/Server.js +0 -40
- package/dist/module/src/server/serverClasees/Server_Base.js +0 -14
- package/dist/module/src/server/serverClasees/Server_Docker.js +0 -897
- package/dist/module/src/server/serverClasees/Server_FS.js +0 -119
- package/dist/module/src/server/serverClasees/Server_HTTP.js +0 -182
- package/dist/module/src/server/serverClasees/Server_WS.js +0 -258
- package/dist/module/src/server/serverManagers/DockerManager.js +0 -28
- package/dist/module/src/server/serverManagers/HttpManager.js +0 -110
- package/dist/module/src/server/serverManagers/WsManager.js +0 -226
- package/dist/module/src/server/serverManagers/fs.js +0 -32
- package/dist/module/src/server/serverManagers/tcp.js +0 -47
- package/dist/module/src/server/types.js +0 -1
- package/dist/module/src/testeranto.js +0 -40
- package/dist/module/src/vscode/TerminalManager.js +0 -92
- package/dist/module/src/vscode/TestTreeItem.js +0 -40
- package/dist/module/src/vscode/extension.js +0 -148
- package/dist/module/src/vscode/providers/FeaturesTreeDataProvider.js +0 -408
- package/dist/module/src/vscode/providers/FileTreeDataProvider.js +0 -153
- package/dist/module/src/vscode/providers/ProcessesTreeDataProvider.js +0 -233
- package/dist/module/src/vscode/providers/ResultsTreeDataProvider.js +0 -50
- package/dist/module/src/vscode/providers/TestTreeDataProvider.js +0 -272
- package/dist/module/src/vscode/types.js +0 -6
- package/dist/module/testeranto/runtimes/node/node.js +0 -5
- package/dist/module/testeranto/runtimes/web/web.js +0 -4
- package/dist/module/testeranto/testeranto.js +0 -68
- package/dist/module/tsconfig.module.tsbuildinfo +0 -1
- package/dist/types/Init.d.ts +0 -2
- package/dist/types/esbuildConfigs/consoleDetectorPlugin.d.ts +0 -2
- package/dist/types/esbuildConfigs/eslint-formatter-testeranto.d.ts +0 -2
- package/dist/types/esbuildConfigs/featuresPlugin.d.ts +0 -5
- package/dist/types/esbuildConfigs/index.d.ts +0 -3
- package/dist/types/esbuildConfigs/inputFilesPlugin.d.ts +0 -7
- package/dist/types/esbuildConfigs/nativeImportDetectorPlugin.d.ts +0 -2
- package/dist/types/esbuildConfigs/rebuildPlugin.d.ts +0 -6
- package/dist/types/init-docs.d.ts +0 -1
- package/dist/types/lib/tiposkripto/Types.d.ts +0 -9
- package/dist/types/lib/tiposkripto/abstractBase.test/MockGiven.d.ts +0 -9
- package/dist/types/lib/tiposkripto/abstractBase.test/MockThen.d.ts +0 -6
- package/dist/types/lib/tiposkripto/abstractBase.test/MockWhen.d.ts +0 -6
- package/dist/types/lib/tiposkripto/abstractBase.test/adapter.d.ts +0 -3
- package/dist/types/lib/tiposkripto/abstractBase.test/implementation.d.ts +0 -3
- package/dist/types/lib/tiposkripto/abstractBase.test/index.d.ts +0 -28
- package/dist/types/lib/tiposkripto/abstractBase.test/specification.d.ts +0 -3
- package/dist/types/lib/tiposkripto/abstractBase.test/types.d.ts +0 -39
- package/dist/types/runtimes.d.ts +0 -2
- package/dist/types/server/aider/configParser.d.ts +0 -11
- package/dist/types/server/aider/docker.d.ts +0 -2
- package/dist/types/server/getRunnables.d.ts +0 -3
- package/dist/types/server/htmlTemplate.d.ts +0 -2
- package/dist/types/server/nodeVersion.d.ts +0 -2
- package/dist/types/server/runtimes/common.d.ts +0 -12
- package/dist/types/server/runtimes/golang/docker.d.ts +0 -5
- package/dist/types/server/runtimes/java/docker.d.ts +0 -14
- package/dist/types/server/runtimes/node/docker.d.ts +0 -14
- package/dist/types/server/runtimes/node/esbuild.d.ts +0 -4
- package/dist/types/server/runtimes/node/node.d.ts +0 -1
- package/dist/types/server/runtimes/python/docker.d.ts +0 -14
- package/dist/types/server/runtimes/ruby/docker.d.ts +0 -14
- package/dist/types/server/runtimes/rust/docker.d.ts +0 -14
- package/dist/types/server/runtimes/web/docker.d.ts +0 -15
- package/dist/types/server/runtimes/web/esbuild.d.ts +0 -4
- package/dist/types/server/runtimes/web/hoist.d.ts +0 -1
- package/dist/types/server/runtimes/web/web.d.ts +0 -1
- package/dist/types/server/serverClasees/Server.d.ts +0 -8
- package/dist/types/server/serverClasees/Server_Base.d.ts +0 -9
- package/dist/types/server/serverClasees/Server_Docker.d.ts +0 -81
- package/dist/types/server/serverClasees/Server_FS.d.ts +0 -0
- package/dist/types/server/serverClasees/Server_HTTP.d.ts +0 -20
- package/dist/types/server/serverClasees/Server_WS.d.ts +0 -23
- package/dist/types/server/serverManagers/DockerManager.d.ts +0 -0
- package/dist/types/server/serverManagers/HttpManager.d.ts +0 -9
- package/dist/types/server/serverManagers/WsManager.d.ts +0 -10
- package/dist/types/server/serverManagers/fs.d.ts +0 -0
- package/dist/types/server/serverManagers/tcp.d.ts +0 -27
- package/dist/types/server/types.d.ts +0 -68
- package/dist/types/testeranto.d.ts +0 -1
- package/dist/types/tsconfig.types.tsbuildinfo +0 -1
- package/dist/types/vscode/TerminalManager.d.ts +0 -18
- package/dist/types/vscode/TestTreeItem.d.ts +0 -13
- package/dist/types/vscode/extension.d.ts +0 -3
- package/dist/types/vscode/providers/FeaturesTreeDataProvider.d.ts +0 -17
- package/dist/types/vscode/providers/FileTreeDataProvider.d.ts +0 -13
- package/dist/types/vscode/providers/ProcessesTreeDataProvider.d.ts +0 -23
- package/dist/types/vscode/providers/ResultsTreeDataProvider.d.ts +0 -10
- package/dist/types/vscode/providers/TestTreeDataProvider.d.ts +0 -16
- package/dist/types/vscode/types.d.ts +0 -14
- package/src/lib/tiposkripto/Tiposkripto.ts +0 -47
- package/src/lib/tiposkripto/types.ts +0 -23
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common}/Types.js +0 -0
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/src}/BaseGiven.js +0 -0
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/src}/BaseSuite.js +0 -0
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/src}/BaseThen.js +0 -0
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/src}/BaseWhen.js +0 -0
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/src}/CoreTypes.js +0 -0
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/tests}/abstractBase.test/MockGiven.js +0 -0
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/tests}/abstractBase.test/MockThen.js +0 -0
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/tests}/abstractBase.test/MockWhen.js +0 -0
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/tests}/abstractBase.test/adapter.js +0 -0
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/tests}/abstractBase.test/implementation.js +0 -0
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/tests}/abstractBase.test/specification.js +0 -0
- /package/{dist/common/src/lib/tiposkripto → src/lib/tiposkripto/dist/common/lib/tiposkripto/tests}/abstractBase.test/types.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module}/Types.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/src}/BaseGiven.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/src}/BaseSuite.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/src}/BaseThen.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/src}/BaseWhen.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/src}/CoreTypes.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/tests}/abstractBase.test/MockGiven.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/tests}/abstractBase.test/MockThen.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/tests}/abstractBase.test/MockWhen.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/tests}/abstractBase.test/adapter.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/tests}/abstractBase.test/implementation.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/tests}/abstractBase.test/specification.js +0 -0
- /package/{dist/module/src/lib/tiposkripto → src/lib/tiposkripto/dist/module/lib/tiposkripto/tests}/abstractBase.test/types.js +0 -0
- /package/src/lib/tiposkripto/{abstractBase.test → tests/abstractBase.test}/implementation.ts +0 -0
- /package/src/lib/tiposkripto/{abstractBase.test → tests/abstractBase.test}/specification.ts +0 -0
- /package/src/lib/tiposkripto/{abstractBase.test → tests/abstractBase.test}/types.ts +0 -0
package/bundle.js
CHANGED
|
@@ -98,14 +98,14 @@ var externalTests = true;
|
|
|
98
98
|
var nodeBuildCommand = (projectConfigPath, nodeConfigPath, testName) => {
|
|
99
99
|
if (externalTests) {
|
|
100
100
|
console.log("external tests", testName);
|
|
101
|
-
return `yarn tsx node_modules/testeranto/src/server/runtimes/node/node.ts /workspace/testeranto/testeranto.ts
|
|
101
|
+
return `yarn tsx node_modules/testeranto/src/server/runtimes/node/node.ts /workspace/testeranto/testeranto.ts /workspace/${nodeConfigPath} ${testName}`;
|
|
102
102
|
} else {
|
|
103
103
|
console.log("not external tests");
|
|
104
104
|
return `yarn tsx src/server/runtimes/node/node.ts /workspace/testeranto/testeranto.ts /workspace/${nodeConfigPath} ${testName}`;
|
|
105
105
|
}
|
|
106
106
|
};
|
|
107
|
-
var nodeBddCommand = (fpath) => {
|
|
108
|
-
return `node ${fpath.split(".").slice(0, -1).concat("mjs").join(".")} /workspace
|
|
107
|
+
var nodeBddCommand = (fpath, nodeConfigPath) => {
|
|
108
|
+
return `node ${fpath.split(".").slice(0, -1).concat("mjs").join(".")} /workspace/${nodeConfigPath}`;
|
|
109
109
|
};
|
|
110
110
|
|
|
111
111
|
// src/server/runtimes/python/docker.ts
|
|
@@ -1046,8 +1046,8 @@ var Server_Docker = class extends Server_WS {
|
|
|
1046
1046
|
const uid = `${runtimeTestsName.toLowerCase()}-${cleanTestName}`;
|
|
1047
1047
|
const bddCommandFunc = runTimeToCompose[runtime][2];
|
|
1048
1048
|
const filePath = `testeranto/bundles/allTests/${runtime}/${tName}`;
|
|
1049
|
-
const command = bddCommandFunc(filePath);
|
|
1050
|
-
console.log("
|
|
1049
|
+
const command = bddCommandFunc(filePath, this.configs.runtimes[runtimeTestsName].buildOptions);
|
|
1050
|
+
console.log("[Server_Docker] BDD command", command);
|
|
1051
1051
|
services[`${uid}-bdd`] = this.bddTestDockerComposeFile(runtime, `${uid}-bdd`, command);
|
|
1052
1052
|
services[`${uid}-aider`] = this.aiderDockerComposeFile(`${uid}-aider`);
|
|
1053
1053
|
}
|
|
@@ -1686,7 +1686,6 @@ if (mode !== "once" && mode !== "dev") {
|
|
|
1686
1686
|
}
|
|
1687
1687
|
var main = async () => {
|
|
1688
1688
|
const config = (await import(process.cwd() + "/testeranto/testeranto.ts")).default;
|
|
1689
|
-
console.log("mark123", config);
|
|
1690
1689
|
await new Server(config, mode).start();
|
|
1691
1690
|
};
|
|
1692
1691
|
main();
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "testeranto",
|
|
3
3
|
"displayName": "Testeranto",
|
|
4
4
|
"description": "the Dockerized, AI powered, BDD test framework for polyglot projects",
|
|
5
|
-
"version": "0.219.
|
|
5
|
+
"version": "0.219.17",
|
|
6
6
|
"engines": {
|
|
7
7
|
"node": ">=20.19.0",
|
|
8
8
|
"vscode": "^1.60.0"
|
|
@@ -145,25 +145,31 @@
|
|
|
145
145
|
]
|
|
146
146
|
},
|
|
147
147
|
"scripts": {
|
|
148
|
+
"buildV3": "sh prebuild.sh; cp ./src/cjs-shim.js ./dist/cjs-shim.js; sh postBuild.sh; yarn bundle",
|
|
149
|
+
"summarizeLicenses": "yarn licenses list > ALL_LICENSES.txt; yarn license-checker >> ALL_LICENSES.txt; yarn license-checker --summary >> ALL_LICENSES.txt",
|
|
150
|
+
"compile-docs": "node scripts/compile-docs.js",
|
|
151
|
+
"prepublish": "self-import",
|
|
152
|
+
"type-check": "yarn tsc --noEmit > tsc.log",
|
|
153
|
+
"type-fix": "aider --model deepseek/deepseek-chat --load type-fix.txt",
|
|
154
|
+
"vscode:prepublish": "yarn run bundle",
|
|
155
|
+
"compile": "yarn run bundle",
|
|
156
|
+
"watch": "yarn run bundle --watch",
|
|
157
|
+
"package": "npx vsce package",
|
|
158
|
+
"package:full": "node scripts/package-extension.js",
|
|
159
|
+
"build-module": "tsc -p tsconfig.module.json",
|
|
160
|
+
"build-common": "tsc -p tsconfig.common.json",
|
|
161
|
+
"build-types": "tsc -p tsconfig.types.json",
|
|
162
|
+
"build": "sh prebuild.sh; cp ./src/cjs-shim.js ./dist/cjs-shim.js; tsc -p tsconfig.module.json; tsc -p tsconfig.common.json; tsc -p tsconfig.types.json; sh postBuild.sh; yarn bundle",
|
|
163
|
+
"bundle": "node bundle.js",
|
|
148
164
|
"mothership": "node dist/prebuild/mothership/index.mjs",
|
|
149
165
|
"build-hard": "rm -rf testeranto/** && yarn build && yarn type-check; yarn t-init; cp dist/prebuild/App.* testeranto; yarn t-build core once; yarn t-run core once",
|
|
150
|
-
"build": "sh prebuild.sh; cp ./src/cjs-shim.js ./dist/cjs-shim.js; tsc -p tsconfig.module.json; tsc -p tsconfig.common.json; tsc -p tsconfig.types.json; sh postBuild.sh; yarn bundle",
|
|
151
166
|
"build3": "yarn bundle; tsc -p tsconfig.types.json",
|
|
152
167
|
"dev": "sh prebuild.sh; cp ./src/cjs-shim.js ./dist/cjs-shim.js; sh postBuild.sh; tsc -p tsconfig.module.json --watch & tsc -p tsconfig.common.json --watch ",
|
|
153
|
-
"bundle": "node bundle.js",
|
|
154
|
-
"build-module": "tsc -p tsconfig.module.json",
|
|
155
|
-
"build-common": "tsc -p tsconfig.common.json",
|
|
156
|
-
"build-types": "tsc -p tsconfig.types.json",
|
|
157
|
-
"type-check": "yarn tsc --noEmit > tsc.log",
|
|
158
|
-
"type-fix": "aider --model deepseek/deepseek-chat --load type-fix.txt",
|
|
159
168
|
"t-build": "tsx src/build.ts",
|
|
160
169
|
"t-run": "tsx src/run.ts",
|
|
161
170
|
"testeranto": "tsx src/testeranto.ts",
|
|
162
171
|
"t-init": "tsx dist/prebuild/init-docs.mjs",
|
|
163
172
|
"t-report": "tsx dist/prebuild/ReportServer.mjs",
|
|
164
|
-
"compile-docs": "node scripts/compile-docs.js",
|
|
165
|
-
"prepublish": "self-import",
|
|
166
|
-
"summarizeLicenses": "yarn licenses list > ALL_LICENSES.txt; yarn license-checker >> ALL_LICENSES.txt; yarn license-checker --summary >> ALL_LICENSES.txt",
|
|
167
173
|
"buildV2": "node bundle.js",
|
|
168
174
|
"devV2": "rm -rf testeranto; yarn t-init; cp ./dist/prebuild/App.* testeranto; cd example && go mod tidy && cd .. && tsx scripts/build-example.ts && yarn testeranto core dev",
|
|
169
175
|
"build:example": "tsx scripts/build-example.ts",
|
|
@@ -180,12 +186,7 @@
|
|
|
180
186
|
"devV2:full": "rm -rf testeranto && npm run build:all && npm run t-init && cp ./dist/prebuild/App.* testeranto && cd example && go mod tidy && cd .. && npm run build:example && npm run testeranto core dev",
|
|
181
187
|
"devV3": "rm -rf testeranto && yarn run t-init && npm run setup:example && npm run build:example && npm run testeranto core dev",
|
|
182
188
|
"devV4": "rm -rf testeranto/bundles/** testeranto/reports/** testeranto/metafiles/** ; yarn bundle && yarn run testeranto allTests.ts once",
|
|
183
|
-
"devV5": "yarn bundle && yarn run testeranto allTests.ts once"
|
|
184
|
-
"vscode:prepublish": "yarn run bundle",
|
|
185
|
-
"compile": "yarn run bundle",
|
|
186
|
-
"watch": "yarn run bundle --watch",
|
|
187
|
-
"package": "npx vsce package",
|
|
188
|
-
"package:full": "node scripts/package-extension.js"
|
|
189
|
+
"devV5": "yarn bundle && yarn run testeranto allTests.ts once"
|
|
189
190
|
},
|
|
190
191
|
"exports": {
|
|
191
192
|
"./src/cjs-shim.ts": {
|
|
@@ -414,4 +415,4 @@
|
|
|
414
415
|
"cucumber",
|
|
415
416
|
"ATDD"
|
|
416
417
|
]
|
|
417
|
-
}
|
|
418
|
+
}
|
package/src/Types.ts
CHANGED
|
@@ -1,37 +1,18 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { Ibdd_in_any, Ibdd_out_any } from "./lib/tiposkripto/CoreTypes";
|
|
1
|
+
import { BaseGiven } from "./lib/tiposkripto/src/BaseGiven";
|
|
2
|
+
import { BaseThen } from "./lib/tiposkripto/src/BaseThen";
|
|
3
|
+
import { BaseWhen } from "./lib/tiposkripto/src/BaseWhen";
|
|
4
|
+
import { Ibdd_in_any, Ibdd_out_any } from "./lib/tiposkripto/src/CoreTypes";
|
|
5
|
+
import { ITestResourceConfiguration } from "./lib/tiposkripto/src/types";
|
|
7
6
|
|
|
8
7
|
export type IChecks = ((x: any) => string)[];
|
|
9
8
|
|
|
10
|
-
export type
|
|
11
|
-
string
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
prompt: string | "?" | undefined;
|
|
18
|
-
failingFeatures: object | undefined;
|
|
19
|
-
}
|
|
20
|
-
> & {
|
|
21
|
-
nodeLogs?: string;
|
|
22
|
-
webLogs?: string;
|
|
23
|
-
pureLogs?: string;
|
|
24
|
-
};
|
|
25
|
-
|
|
26
|
-
export type SuiteSpecification<
|
|
27
|
-
I extends Ibdd_in_any,
|
|
28
|
-
O extends Ibdd_out_any
|
|
29
|
-
> = {
|
|
30
|
-
[K in keyof O["suites"]]: (
|
|
31
|
-
name: string,
|
|
32
|
-
givens: IGivens<I>
|
|
33
|
-
) => BaseSuite<I, O>;
|
|
34
|
-
};
|
|
9
|
+
export type IBaseTestConfig = {
|
|
10
|
+
runtime: string;
|
|
11
|
+
tests: string[];
|
|
12
|
+
dockerfile: string;
|
|
13
|
+
buildOptions: string,
|
|
14
|
+
checks: IChecks;
|
|
15
|
+
}
|
|
35
16
|
|
|
36
17
|
// Simplified test result summary
|
|
37
18
|
export type TestSummary = {
|
|
@@ -172,142 +153,3 @@ export type IPluginFactory = (
|
|
|
172
153
|
export type IRunTime = `node` | `web` | `golang` | `python` | `ruby` | `java` | `rust`;
|
|
173
154
|
|
|
174
155
|
export type ITestTypes = [string, IRunTime, { ports: number }, ITestTypes[]];
|
|
175
|
-
|
|
176
|
-
export type IDockerSteps = "RUN" | "WORKDIR" | "COPY";
|
|
177
|
-
|
|
178
|
-
export type IBaseTestConfig = {
|
|
179
|
-
runtime: string;
|
|
180
|
-
tests: string[];
|
|
181
|
-
dockerfile: string;
|
|
182
|
-
buildOptions: string,
|
|
183
|
-
checks: IChecks;
|
|
184
|
-
}
|
|
185
|
-
|
|
186
|
-
export type ITestconfigV2Node = IBaseTestConfig & { plugins: any[] }
|
|
187
|
-
|
|
188
|
-
export type ITestconfigV2 = {
|
|
189
|
-
featureIngestor: (s: string) => Promise<string>;
|
|
190
|
-
|
|
191
|
-
runtimes: Record<string, IBaseTestConfig>
|
|
192
|
-
|
|
193
|
-
// java?: IBaseTestConfig;
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
// rust?: IBaseTestConfig;
|
|
197
|
-
|
|
198
|
-
// ruby: {
|
|
199
|
-
// plugins: any[];
|
|
200
|
-
// tests: Record<string, { ports: number }>;
|
|
201
|
-
// loaders: Record<string, string>;
|
|
202
|
-
// checks: IChecks;
|
|
203
|
-
// dockerfile: string;
|
|
204
|
-
// };
|
|
205
|
-
|
|
206
|
-
// golang: {
|
|
207
|
-
// plugins: any[];
|
|
208
|
-
// tests: Record<string, { ports: number }>;
|
|
209
|
-
// loaders: Record<string, string>;
|
|
210
|
-
// checks: IChecks;
|
|
211
|
-
// dockerfile: string;
|
|
212
|
-
// };
|
|
213
|
-
|
|
214
|
-
// python: {
|
|
215
|
-
// plugins: any[];
|
|
216
|
-
// tests: Record<string, { ports: number }>;
|
|
217
|
-
// loaders: Record<string, string>;
|
|
218
|
-
// checks: IChecks;
|
|
219
|
-
// dockerfile: string;
|
|
220
|
-
// };
|
|
221
|
-
|
|
222
|
-
// node: {
|
|
223
|
-
// plugins: any[];
|
|
224
|
-
// tests: Record<string, { ports: number }>;
|
|
225
|
-
// loaders: Record<string, string>;
|
|
226
|
-
// externals: string[];
|
|
227
|
-
// checks: IChecks;
|
|
228
|
-
// dockerfile: string;
|
|
229
|
-
// };
|
|
230
|
-
|
|
231
|
-
// web: {
|
|
232
|
-
// plugins: any[];
|
|
233
|
-
// tests: Record<string, { ports: number }>;
|
|
234
|
-
// loaders: Record<string, string>;
|
|
235
|
-
// externals: string[];
|
|
236
|
-
// checks: IChecks;
|
|
237
|
-
// dockerfile: string;
|
|
238
|
-
// };
|
|
239
|
-
};
|
|
240
|
-
|
|
241
|
-
// export type ITestconfig = {
|
|
242
|
-
// httpPort: number;
|
|
243
|
-
|
|
244
|
-
// featureIngestor: (s: string) => Promise<string>;
|
|
245
|
-
// importPlugins: IPluginFactory[];
|
|
246
|
-
// ports: string[];
|
|
247
|
-
// src: string;
|
|
248
|
-
// check: string;
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
// java: {
|
|
252
|
-
// plugins: any[];
|
|
253
|
-
// tests: Record<string, { ports: number }>;
|
|
254
|
-
// loaders: Record<string, string>;
|
|
255
|
-
// checks: IChecks;
|
|
256
|
-
// dockerfile: string;
|
|
257
|
-
// };
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
// rust: {
|
|
261
|
-
// plugins: any[];
|
|
262
|
-
// tests: Record<string, { ports: number }>;
|
|
263
|
-
// loaders: Record<string, string>;
|
|
264
|
-
// checks: IChecks;
|
|
265
|
-
// dockerfile: string;
|
|
266
|
-
// };
|
|
267
|
-
|
|
268
|
-
// ruby: {
|
|
269
|
-
// plugins: any[];
|
|
270
|
-
// tests: Record<string, { ports: number }>;
|
|
271
|
-
// loaders: Record<string, string>;
|
|
272
|
-
// checks: IChecks;
|
|
273
|
-
// dockerfile: string;
|
|
274
|
-
// };
|
|
275
|
-
|
|
276
|
-
// golang: {
|
|
277
|
-
// plugins: any[];
|
|
278
|
-
// tests: Record<string, { ports: number }>;
|
|
279
|
-
// loaders: Record<string, string>;
|
|
280
|
-
// checks: IChecks;
|
|
281
|
-
// dockerfile: string;
|
|
282
|
-
// };
|
|
283
|
-
|
|
284
|
-
// python: {
|
|
285
|
-
// plugins: any[];
|
|
286
|
-
// tests: Record<string, { ports: number }>;
|
|
287
|
-
// loaders: Record<string, string>;
|
|
288
|
-
// checks: IChecks;
|
|
289
|
-
// dockerfile: string;
|
|
290
|
-
// };
|
|
291
|
-
|
|
292
|
-
// node: {
|
|
293
|
-
// plugins: any[];
|
|
294
|
-
// tests: Record<string, { ports: number }>;
|
|
295
|
-
// loaders: Record<string, string>;
|
|
296
|
-
// externals: string[];
|
|
297
|
-
// checks: IChecks;
|
|
298
|
-
// dockerfile: string;
|
|
299
|
-
// };
|
|
300
|
-
|
|
301
|
-
// web: {
|
|
302
|
-
// plugins: any[];
|
|
303
|
-
// tests: Record<string, { ports: number }>;
|
|
304
|
-
// loaders: Record<string, string>;
|
|
305
|
-
// externals: string[];
|
|
306
|
-
// checks: IChecks;
|
|
307
|
-
// dockerfile: string;
|
|
308
|
-
// };
|
|
309
|
-
// };
|
|
310
|
-
|
|
311
|
-
// export type IBuiltConfig = { buildDir: string } & ITestconfig;
|
|
312
|
-
|
|
313
|
-
// export type IConfig = Map<string, [IRunTime, string, string, { tests: string[] }]>
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
|
|
2
|
+
import * as esbuild from 'esbuild'
|
|
3
|
+
|
|
4
|
+
await esbuild.build({
|
|
5
|
+
outExtension: { '.js': '.mjs' },
|
|
6
|
+
entryPoints: [
|
|
7
|
+
'src/index.mts',
|
|
8
|
+
],
|
|
9
|
+
bundle: true,
|
|
10
|
+
format: "esm",
|
|
11
|
+
splitting: true,
|
|
12
|
+
platform: "node",
|
|
13
|
+
target: "node20",
|
|
14
|
+
outdir: "dist/prebuild",
|
|
15
|
+
packages: "external",
|
|
16
|
+
supported: {
|
|
17
|
+
"dynamic-import": true,
|
|
18
|
+
},
|
|
19
|
+
external: [
|
|
20
|
+
"fs", "path", "child_process", "util", "os", "events", "stream",
|
|
21
|
+
"http", "https", "zlib", "crypto", "buffer", "net", "dns", "tls",
|
|
22
|
+
"assert", "querystring", "punycode", "readline", "repl", "vm",
|
|
23
|
+
"perf_hooks", "async_hooks", "timers", "console", "module", "process",
|
|
24
|
+
"vscode"
|
|
25
|
+
],
|
|
26
|
+
})
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
2
|
+
/* eslint-disable no-undef */
|
|
3
|
+
import { createRequire } from 'node:module';
|
|
4
|
+
import path from 'node:path';
|
|
5
|
+
import url from 'node:url';
|
|
6
|
+
|
|
7
|
+
// globalThis.require = createRequire(import.meta.url);
|
|
8
|
+
globalThis.__filename = url.fileURLToPath(import.meta.url);
|
|
9
|
+
globalThis.__dirname = path.dirname(__filename);
|
|
10
|
+
|
|
11
|
+
// const p = `${import.meta.url}/..`;
|
|
12
|
+
// globalThis.require = createRequire(`${import.meta.url}/..`);
|
|
13
|
+
// globalThis.__filename = url.fileURLToPath(`${import.meta.url}/..`);
|
|
14
|
+
// globalThis.__dirname = path.dirname(`${__filename}/..`);
|
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
const index_mjs_1 = require("./index.mjs");
|
|
3
4
|
const BaseGiven_1 = require("./BaseGiven");
|
|
4
5
|
const BaseSuite_1 = require("./BaseSuite");
|
|
5
|
-
const
|
|
6
|
-
const
|
|
7
|
-
const
|
|
6
|
+
const BaseThen_1 = require("./BaseThen");
|
|
7
|
+
const BaseWhen_1 = require("./BaseWhen");
|
|
8
|
+
const types_js_1 = require("./types.js");
|
|
8
9
|
class BaseTiposkripto {
|
|
9
|
-
constructor(webOrNode, input, testSpecification, testImplementation, testResourceRequirement =
|
|
10
|
+
constructor(webOrNode, input, testSpecification, testImplementation, testResourceRequirement = types_js_1.defaultTestResourceRequirement, testAdapter = {}, testResourceConfiguration, wsPort = "3456", wsHost = "localhost") {
|
|
10
11
|
this.totalTests = 0;
|
|
11
12
|
this.artifacts = [];
|
|
12
13
|
this.testResourceConfiguration = testResourceConfiguration;
|
|
13
|
-
const fullAdapter = (0,
|
|
14
|
+
const fullAdapter = (0, index_mjs_1.DefaultAdapter)(testAdapter);
|
|
14
15
|
if (!testImplementation.suites ||
|
|
15
16
|
typeof testImplementation.suites !== "object") {
|
|
16
17
|
throw new Error(`testImplementation.suites must be an object, got ${typeof testImplementation.suites}: ${JSON.stringify(testImplementation.suites)}`);
|
|
@@ -52,7 +53,7 @@ class BaseTiposkripto {
|
|
|
52
53
|
}, {});
|
|
53
54
|
const classyWhens = Object.entries(testImplementation.whens).reduce((a, [key, whEn]) => {
|
|
54
55
|
a[key] = (...payload) => {
|
|
55
|
-
const whenInstance = new (class extends
|
|
56
|
+
const whenInstance = new (class extends BaseWhen_1.BaseWhen {
|
|
56
57
|
async andWhen(store, whenCB, testResource) {
|
|
57
58
|
return await fullAdapter.andWhen(store, whenCB, testResource);
|
|
58
59
|
}
|
|
@@ -63,7 +64,7 @@ class BaseTiposkripto {
|
|
|
63
64
|
}, {});
|
|
64
65
|
const classyThens = Object.entries(testImplementation.thens).reduce((a, [key, thEn]) => {
|
|
65
66
|
a[key] = (...args) => {
|
|
66
|
-
const thenInstance = new (class extends
|
|
67
|
+
const thenInstance = new (class extends BaseThen_1.BaseThen {
|
|
67
68
|
async butThen(store, thenCB, testResource) {
|
|
68
69
|
return await fullAdapter.butThen(store, thenCB, testResource);
|
|
69
70
|
}
|
|
@@ -5,11 +5,11 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.NodeTiposkripto = void 0;
|
|
7
7
|
const fs_1 = __importDefault(require("fs"));
|
|
8
|
-
const
|
|
9
|
-
const
|
|
8
|
+
const BaseTiposkripto_1 = __importDefault(require("./BaseTiposkripto"));
|
|
9
|
+
const types_1 = require("./types");
|
|
10
10
|
console.log(`[NodeTiposkripto] ${process.argv}`);
|
|
11
11
|
const config = { ports: [1111], fs: 'testeranto/reports/allTests/example/Calculator.test/node' };
|
|
12
|
-
class NodeTiposkripto extends
|
|
12
|
+
class NodeTiposkripto extends BaseTiposkripto_1.default {
|
|
13
13
|
constructor(input, testSpecification, testImplementation, testResourceRequirement, testAdapter) {
|
|
14
14
|
// console.log(`[NodeTiposkripto] constructor ${process.argv[3]}`);
|
|
15
15
|
// const config = JSON.parse(process.argv[3])
|
|
@@ -26,7 +26,7 @@ class NodeTiposkripto extends BaseTiposkripto_js_1.default {
|
|
|
26
26
|
}
|
|
27
27
|
}
|
|
28
28
|
exports.NodeTiposkripto = NodeTiposkripto;
|
|
29
|
-
const tiposkripto = async (input, testSpecification, testImplementation, testAdapter, testResourceRequirement =
|
|
29
|
+
const tiposkripto = async (input, testSpecification, testImplementation, testAdapter, testResourceRequirement = types_1.defaultTestResourceRequirement) => {
|
|
30
30
|
try {
|
|
31
31
|
const t = new NodeTiposkripto(input, testSpecification, testImplementation, testResourceRequirement, testAdapter);
|
|
32
32
|
return t;
|
|
@@ -5,7 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.WebTiposkripto = void 0;
|
|
7
7
|
const BaseTiposkripto_js_1 = __importDefault(require("./BaseTiposkripto.js"));
|
|
8
|
-
const
|
|
8
|
+
const types_js_1 = require("./types.js");
|
|
9
9
|
const config = {
|
|
10
10
|
name: 'web',
|
|
11
11
|
fs: 'testeranto/reports/allTests/example/Calculator.test/web',
|
|
@@ -50,7 +50,7 @@ class WebTiposkripto extends BaseTiposkripto_js_1.default {
|
|
|
50
50
|
}
|
|
51
51
|
}
|
|
52
52
|
exports.WebTiposkripto = WebTiposkripto;
|
|
53
|
-
const tiposkripto = async (input, testSpecification, testImplementation, testAdapter, testResourceRequirement =
|
|
53
|
+
const tiposkripto = async (input, testSpecification, testImplementation, testAdapter, testResourceRequirement = types_js_1.defaultTestResourceRequirement) => {
|
|
54
54
|
try {
|
|
55
55
|
const t = new WebTiposkripto(input, testSpecification, testImplementation, testResourceRequirement, testAdapter);
|
|
56
56
|
// const data = navigator.storage.
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
import { defaultTestResourceRequirement } from "./types";
|
|
3
|
+
// let tpskrt;
|
|
4
|
+
// // Use esbuild define to distinguish environments
|
|
5
|
+
// declare const ENV: "node" | "web";
|
|
6
|
+
// if (ENV === "node") {
|
|
7
|
+
// tpskrt = await import("./Node");
|
|
8
|
+
// } else if (ENV === "web") {
|
|
9
|
+
// tpskrt = await import("./Web");
|
|
10
|
+
// } else {
|
|
11
|
+
// throw `Unknown ENV ${ENV}`;
|
|
12
|
+
// }
|
|
13
|
+
let tpskrt;
|
|
14
|
+
const tpskrtNode = await import("./Node");
|
|
15
|
+
const tpskrtWeb = await import("./Web");
|
|
16
|
+
if (ENV === "node") {
|
|
17
|
+
tpskrt = tpskrtNode;
|
|
18
|
+
}
|
|
19
|
+
else if (ENV === "web") {
|
|
20
|
+
tpskrt = tpskrtWeb;
|
|
21
|
+
}
|
|
22
|
+
else {
|
|
23
|
+
throw `Unknown ENV ${ENV}`;
|
|
24
|
+
}
|
|
25
|
+
export default async (input, testSpecification, testImplementation, testAdapter, testResourceRequirement = defaultTestResourceRequirement, testResourceConfiguration) => {
|
|
26
|
+
return (await tpskrt.default)(input, testSpecification, testImplementation, testResourceRequirement, testAdapter, testResourceConfiguration);
|
|
27
|
+
};
|
|
28
|
+
export const BaseAdapter = () => ({
|
|
29
|
+
beforeAll: async (input, testResource) => {
|
|
30
|
+
return input;
|
|
31
|
+
},
|
|
32
|
+
beforeEach: async function (subject, initializer, testResource, initialValues) {
|
|
33
|
+
return subject;
|
|
34
|
+
},
|
|
35
|
+
afterEach: async (store, key) => Promise.resolve(store),
|
|
36
|
+
afterAll: (store) => undefined,
|
|
37
|
+
butThen: async (store, thenCb, testResource) => {
|
|
38
|
+
return thenCb(store);
|
|
39
|
+
},
|
|
40
|
+
andWhen: async (store, whenCB, testResource) => {
|
|
41
|
+
return whenCB(store);
|
|
42
|
+
},
|
|
43
|
+
assertThis: (x) => x,
|
|
44
|
+
});
|
|
45
|
+
export const DefaultAdapter = (p) => {
|
|
46
|
+
const base = BaseAdapter();
|
|
47
|
+
return Object.assign(Object.assign({}, base), p);
|
|
48
|
+
};
|
|
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
const Tiposkripto_1 = __importDefault(require("
|
|
6
|
+
const Tiposkripto_1 = __importDefault(require("../../src/Tiposkripto"));
|
|
7
7
|
const adapter_1 = require("./adapter");
|
|
8
8
|
const implementation_1 = require("./implementation");
|
|
9
9
|
const MockGiven_1 = require("./MockGiven");
|