Reputation: 693
I am very new to Codeceptjs
. I'm using Visual Studio Code to write some sample tests. It will really help me if I could have something like an auto-complete for the methods so when I typed for instance I.see
it shows me the options that I have, for instance, seeInCurrentUrl
.
Tried but couldn't find any plugins for VSC do you know any? or any other ways to do that?
Upvotes: 1
Views: 1712
Reputation: 499
In steps_file.ts, try to change the following line:
// module.exports = function() {
export = function() {
return actor({
// Define custom steps here, use 'this' to access default methods of I.
// It is recommended to place a general 'login' function here.
})
}
Upvotes: -1
Reputation: 46
Check the docs. You can add the definitions by doing https://codecept.io/commands#typescript-definitions
You run
npx codeceptjs def
to install the auto-complete definitions and then add
/// <reference path="./steps.d.ts" />
at the top of each file. Hope that helps.
Upvotes: 2