Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

flyskywhy
Copy link
Contributor

xpathLocator() in WebDriverIO.js take too long time, and locator ~ does not need it, so be the 1st commit.

JS code write once run on Android, iOS and Web by react-native and react-web, now test case with locator ~ write once run on them too, so be the 1st and 2nd commit.

@DavertMik
Copy link
Contributor

This change breaks build for Appium. Please check https://semaphoreci.com/codeception/codeceptjs/branches/pull-request-728/builds/1 for details

@DavertMik DavertMik requested a review from APshenkin November 26, 2017 11:21
@DavertMik
Copy link
Contributor

Looks good to me. Area-label should be added to documentation.

JS code write once run on Android, iOS and Web by react-native and react-web, now test case with locator ~ write once run on them too, so be the 1st and 2nd commit.

@flyskywhy could you bring the small example with React native - react-web with area-label ?
I mean an example of sample component so I could add it to documentation. This looks like could be really popular use case

flyskywhy added a commit to flyskywhy/noder-react-native that referenced this pull request Dec 2, 2017
@flyskywhy
Copy link
Contributor Author

A small sample component could be:

<Text accessibilityLabel="foobar">
    CodeceptJS is awesome
</Text>

A full example of app and test write once run on Android, iOS and Web is my forked and modified noder-react-native , I just test it in Android and Web successfully with the README.md . The src/components/ScrollableTabs.js use

this.props.tabs.map((item, index)=> {
...
    <Text accessibilityLabel={item} style={styles.itemText}>
        { item }
    </Text>
...
});

then the tab on the homepage can be clicked by e.g. I.click('~问答') in e2e/tests/clickSome.js . because the tabs={['精华', '问答', '主页', '分享', '招聘']} comes from src/layouts/Home.js

After you accept the PR and publish a new version, then I can remove "patch-codeceptjs-webdriverio": "wget https://raw.githubusercontent.com/flyskywhy/CodeceptJS/master/lib/helper/WebDriverIO.js -O node_modules/codeceptjs-webdriverio/node_modules/codeceptjs/lib/helper/WebDriverIO.js" in package.json of noder-react-native .

ps: that's aria-label not area-label 😝

@DavertMik
Copy link
Contributor

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants