-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Custom parameters support + Hook conflict fix #182
Conversation
BugDiver
commented
Jun 16, 2024
- Add support for custom parameter parsing Add support for enum parameters #5
- Fix conflicting hooks issues multiple @BeforeSuite conflict #138
* Parse primitive paramters * Support custom parameter parser Signed-off-by: BugDiver <[email protected]>
Signed-off-by: BugDiver <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Taking a look at this meanwhile I noticed what might be typos. Can you check if it's worth changing the spelling?
docs/index.md
Outdated
@@ -309,6 +309,63 @@ String elementId = scenarioStore.get("element-id") as string; | |||
|
|||
``` | |||
|
|||
### Custom Paramter Parsers |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
### Custom Paramter Parsers | |
### Custom Parameter Parsers |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor comments otherwise all else looks ok!
e2e/tests/implementation.ts
Outdated
@Step("This step uses a custom parameter of type Person and value <person>") | ||
public async validatePerson(person: Person) { | ||
assert.equal(person.name, "John"); | ||
assert.equal(person.age, 30); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we change these to use strictEqual
? I noticed that even if the parameter was declared as a number
in earlier versions the number is actually passed as string
and fails when we do a ===
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, this should be fixed now, as we are doing primitive conversion. Just to highlight, parameters which are part of a table (string or int or bool) are still treated as string
. As of now we are not doing nested conversion.
Signed-off-by: BugDiver <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Two more typos otherwise all good.
Signed-off-by: BugDiver <[email protected]>
79b4754
to
ffd91c0
Compare
@BugDiver Thank you for contributing to gauge-ts. Your pull request has been labeled as a release candidate 🎉🎉. Merging this PR will trigger a release. Please bump up the version as part of this PR.Instructions to bump the version can found at CONTRIBUTING.md If the CONTRIBUTING.md file does not exist or does not include instructions about bumping up the version, please looks previous commits in git history to see what changes need to be done. |