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
#!/bin/bash | |
# | |
# Convert diff output to colorized HTML. | |
# (C) Mitch Frazier, 2008-08-27 | |
# http://www.linuxjournal.com/content/convert-diff-output-colorized-html | |
# Modified by stopyoukid | |
# | |
html="<html><head><meta charset=\"utf-8\"><title>Pretty Diff</title><style>body {text-align: center;}#wrapper {display: inline-block;margin-top: 1em;min-width: 800px;text-align: left;}h2 {background: #fafafa;background: -moz-linear-gradient(#fafafa, #eaeaea);background: -webkit-linear-gradient(#fafafa, #eaeaea);-ms-filter: \"progid:DXImageTransform.Microsoft.gradient(startColorstr='#fafafa',endColorstr='#eaeaea')\";border: 1px solid #d8d8d8;border-bottom: 0;color: #555;font: 14px sans-serif;overflow: hidden;padding: 10px 6px;text-shadow: 0 1px 0 white;margin: 0;}.file-diff {border: 1px solid #d8d8d8;margin-bottom: 1em;overflow: auto;padding: 0.5em 0;}.file-diff > div {width: 100%:}pre {margin: 0;font-family: \"Bitstream Vera Sans Mono\", Courier, monospace;font-size: 12px;line-height: 1.4em;text-indent: 0.5em;}.file {color: |
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
import 'dart:async'; | |
import 'package:flutter_gherkin/flutter_gherkin.dart'; | |
import 'package:gherkin/gherkin.dart'; | |
import 'package:glob/glob.dart'; | |
import 'hooks/hook_example.dart'; | |
import 'steps/step_definition.dart'; | |
Future<void> main() { | |
final config = FlutterTestConfiguration() | |
..features = [Glob(r"test_driver/features/**.feature")] |
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
import '../pages/landing_page.dart'; | |
class TapButtonNTimesStep extends When2WithWorld<String, int, FlutterWorld> { | |
TapButtonNTimesStep() | |
: super(StepDefinitionConfiguration()..timeout = Duration(seconds: 30)); | |
@override | |
Future<void> executeStep(String key, int times) async { | |
final landingPage = new LandingPage(world.driver); | |
await landingPage.tapPlusOneBtnForNTimes(key, times, world); |
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
Feature: Hello World | |
Hello World feature test | |
Scenario: Check App Title And Content | |
Given I expect the "firstTabTitle" to be "Jeresy Cool!" | |
Then I expect the "textField" to be "Hello, Jersey!" | |
Scenario: Check App Title When Switch Page | |
Given I go to second page | |
Then I expect second page title to be "Jersey Second Tab" |
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
self.application = application | |
//A Given step definition | |
Given("the app is running") { (args, userInfo) -> Void in | |
application.launch() | |
} | |
//Another step definition | |
MatchAll("I select \"([^\\\"]*)\"") { (args, userInfo) -> Void in | |
let mealName = args?[0] |
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
Feature: FoodTracker Cucumberish Exapmle | |
Scenario: Verify Meal Caption | |
Given the app is running | |
When I select "Caprese Salad" | |
Then I should see Caprese Salad | |
Scenario Outline: Verify Meal Rating | |
When I select "<meal>" | |
And I rating as <star> |
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
import Cucumberish | |
@objc class CucumberishInitializer: NSObject { | |
@objc class func CucumberishSwiftInit() | |
{ | |
//Using XCUIApplication only available in XCUI test targets not the normal Unit test targets. | |
var application : XCUIApplication! | |
//A closure that will be executed only before executing any of your features | |
beforeStart { () -> Void in | |
//Any global initialization can go here |