Giter VIP home page Giter VIP logo

codecept-typescript-example's People

Contributors

dependabot[bot] avatar elukoyanov avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

codecept-typescript-example's Issues

Tests cannot run on windows machine

Windows OS could not run "test:e2e": "TS_NODE_PROJECT='./src/specs/e2e/tsconfig.json' codeceptjs run" command.

TS_NODE_PROJECT='./src/specs/e2e/tsconfig.json' is a linux way to set up environment variables.

Windows has set TS_NODE_PROJECT './src/specs/e2e/tsconfig.json' style.

Add TSC example of using

Currently ts-node package is used to run tests.
Maybe, using tsc directly will be interested for someone to avoid unnecessary packages (and their possible bugs)

  • create script, that will use tsc compiler without ts-node

Add simple app

For stable testing should be created a simple app.
Instead of using github in tests.

  • create simple one-page-app
  • add local server for app
  • rewrite tests to use this app

Add a CI with test run

Create an CI for example, which start app and runs tests.

  • Add CI
  • Add e2e tests run in CI
  • Describe how it's works in comments or README

Add FAQ and "why"s to README

Currently, project is works and show a simple example of project structure and tests.

But, some JS/TS/Codecept newbies don't know what to pay attention.

  • Why and where the tsconfig is placed. How is it used. Why are 2 tsconfig placed in repository.
  • Where types for Codecept are placed and how them can be updated.
  • How to work with Windows OS. What are the differences.

when there are multiple page files and steps file, then typescript defination doesn't work properly

when we run command : npx codeceptjs def

1 const { I } = inject();
~
'I' was also declared here.

at createTSError (.../node_modules/ts-node/src/index.ts:859:12)
at reportTSError (.../node_modules/ts-node/src/index.ts:863:19)
at getOutput (.../node_modules/ts-node/src/index.ts:1077:36)
at Object.compile (.../node_modules/ts-node/src/index.ts:1433:41)
at Module.m._compile (.../node_modules/ts-node/src/index.ts:1617:30)
at Module._extensions..js (node:internal/modules/cjs/loader:1209:10)
at Object.require.extensions. [as .ts] (.../node_modules/ts-node/src/index.ts:1621:12)
at Module.load (node:internal/modules/cjs/loader:1033:32)
at Function.Module._load (node:internal/modules/cjs/loader:868:12)
at Module.require (node:internal/modules/cjs/loader:1057:19)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.