-
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
Start adding docs via typedoc #659
Merged
Merged
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
35e8eb4
Start adding docs via typedoc
jnicklas 08be6a8
Upgrade to TypeDoc beta
jnicklas 392901a
Add more docs
jnicklas 5021f7a
Skip README
jnicklas c318bf1
Add dedicated start page for API docs
jnicklas fbed19a
Start adding docs for other interactor
jnicklas 0e9a23e
Add typedoc support for sub-packages
jnicklas e2031e3
Improve suite docs
jnicklas a21aefb
Document interactor class
jnicklas c9ccbcb
Add documentation for built in interactors
jnicklas aa858f6
Hide deprecated App interactor in docs
jnicklas 5272efc
Document helper functions
jnicklas 4540c9e
Document `Page`
jnicklas a1c4df8
Some more docs
jnicklas File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
node_modules | ||
yarn-error.log | ||
/packages/*/dist | ||
/packages/*/docs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# BigTest | ||
|
||
This is cool stuff {@link createInteractor}, yeah! | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
export * from '@bigtest/interactor'; | ||
export * from '@bigtest/suite'; | ||
export { test, TestBuilder } from '@bigtest/suite'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
{ | ||
"out": "docs", | ||
"name": "BigTest", | ||
"entryPoints": "src/index.ts", | ||
"readme": "API.md", | ||
"includeVersion": true | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
# Interactors | ||
|
||
## Built in interactors | ||
|
||
We provide a set of interactors built in. | ||
|
||
## Custom interactors | ||
|
||
You can create your own interactors with {@link createInteractor}. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,30 @@ | ||
import { createInteractor } from '../create-interactor'; | ||
import { isVisible } from 'element-is-visible'; | ||
|
||
export const Heading = createInteractor<HTMLHeadingElement>('heading')({ | ||
const HeadingInteractor = createInteractor<HTMLHeadingElement>('heading')({ | ||
selector: 'h1,h2,h3,h4,h5,h6', | ||
filters: { | ||
level: (element) => parseInt(element.tagName[1]), | ||
visible: { apply: isVisible, default: true }, | ||
} | ||
}); | ||
|
||
/** | ||
* Call this {@link InteractorConstructor} to initialize a heading {@link Interactor}. | ||
* The heading interactor can be used to assert on the state of headings on the page, | ||
* represented by the `h1` through `h6` tags. | ||
* | ||
* ### Example | ||
* | ||
* ``` typescript | ||
* await Heading('Welcome!').exists(); | ||
* ``` | ||
* | ||
* ### Filters | ||
* | ||
* - `level`: *number* β The level of the heading, for example, the level of `h3` is `3`. | ||
* - `visible`: *boolean* β Filter by visibility. Defaults to `true`. See {@link isVisible}. | ||
* | ||
* @category Interactor | ||
*/ | ||
export const Heading = HeadingInteractor; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
This file is just a placeholder, we'll want to expand this to link to the most relevant parts of the documentation.