eridem / patata Goto Github PK
View Code? Open in Web Editor NEW๐ Patata - Mobile Behaviour Driven Development made it easy -
Home Page: http://patata.io
License: MIT License
๐ Patata - Mobile Behaviour Driven Development made it easy -
Home Page: http://patata.io
License: MIT License
I have tests running, but I am not exactly sure how to access the iOS driver from my definitions files... I expected a global driver variable but it does not exist, this.emu seems to be what the documentation points to using but this.emu.getScreenshot does not exist...
Built in hooks seem to indicate patata.emulator.driver.takeScreenshot() works and I need to require in patata in each test, is this the case?
should not be too hard... then we have one tool to rule them all!
When developing while using Cordova, or in my case ReactNative especially, but even regular native apps... spinning up appium server takes a while compared to just rebuilding the app... this is fine when running on a CI server, but it seems to me we need a dev mode for engineers to spin up a server and quickly run the cucumber tests as they are working on the project. Thoughts?
If you write all your tests ahead of time, you might not want to fail your tests when not everything works, this will clog up a build server that simply needs to generate a report and a progress build of the app. We need a progressBuild cli flag to not fail on test failure
I purpose that patata support searching in the same level as features and config for a folder called definition so optional you can separate definitions into their own folder if you so choose.
Create a container for available environments. E.g. Android.
It should have everything installed so developers does not need to worry about installing tools (e. g. Java)
Just as calabash has generic predefined step definitions, I think patata should too:
You can take a screenshot
Coordinate based touches
Touching arbitrary views by accessibility label:
Buttons by accessibility label
or by number/index (note number starts with 1 not 0)
Input fields (UITextFields). Note, this looks for an UITextField with the placeholder property set to the quoted string.
List items (UITableViewCells) by number. Note this can only be used to touch visible cells - it doesn't try to scroll down/up.
Switches (UISwitch),
this step works if there is a single switch. Otherwise use,
Built-in keyboard. Touching the Done/Search button
Entering text by accessibility label:
Text by table (fields are by "placeholder")
Text by input field number:
Clearing fields (like entering "")
Clearing fields by number
Waiting for text, or a view with a certain accessibilityLabel
wait for something to disappear
waiting for a button with an accessibilityLabel
waiting for an iOS navigation bar with a certain title,
waiting for a text field
waiting for a number of text fields
waiting in general
In an iOS navigation bar, you can touch the "back" button using
Swiping an unspecified place (usually when you have big scroll view in the center of the screen). Swipe directions can be left, right, up and down.
Swiping a scroll view by index/number (and offset), or accessibilityLabel
Swiping table cells, by number
This step makes a small pinch to zoom in or out. Either at the first scroll view of the screen, or a the center of a view with a certain accessibility label.
Scrolling on scroll views. Direction can be left, right, up or down.
You can rotate the device or simulator left or right.
Assertions
Like waiting, these are usually about seeing certain text or ui components. Usually these are identified by their accessibilityLabels, component type (like a navigation bar) or pure text like in a label or a web view.
If the thing being asserted doesn't exist in the view, the test will fail.
Asserting existence of text, or a view with a certain accessibilityLabel
Asserting existence of buttons:
More on text, prefix, suffix, and sub string.
Seeing some text fields
Seeing maps and user location
Per #6 this is no correct behavior and does not seem to work this way on android.
##Expected result:
No tags defined in the CLI, and all tests should be run.
As I am working on pushing this forward, I am just curious as to a few engineering choices.
Why are all items required and then passed around as the deps variable? this makes it really hard to follow the code imho vs the normal process of just require what ya need.
Why is there a patata.yaml, and a config/config.yaml... both are required or are created yes none of the values are truly needed?
I get a default, but can we make the path to features a config option?
The log.exit method makes tracking down issues really hard due to lack of stack trace... can we improve on that?
The breakdown of features to step definitions is great on one hand, but I know for me and my team we would rather have JUST global, generic definitions, and only use specific ones if needed... Can we support that mindset here too?
init command is really cool, but if there is already a package.json can't we have it just add whats needed to the existing project?
Thank yo very much for indulging me here. Once I understand these items better I will be happy to help implement what needs done and PR it
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.