From 5523f9f656b733a3bf257e89a7aefdeb96984597 Mon Sep 17 00:00:00 2001 From: Sirajuddin Khan Date: Thu, 10 Dec 2020 22:27:29 +0000 Subject: [PATCH 1/2] gitpod yml --- .gitpod.Dockerfile | 12 ++++++++++++ .gitpod.yml | 14 ++++++++++++++ tests/DuskTestCase.php | 25 ++++++++++--------------- 3 files changed, 36 insertions(+), 15 deletions(-) create mode 100644 .gitpod.Dockerfile create mode 100644 .gitpod.yml diff --git a/.gitpod.Dockerfile b/.gitpod.Dockerfile new file mode 100644 index 0000000..bfcf814 --- /dev/null +++ b/.gitpod.Dockerfile @@ -0,0 +1,12 @@ +FROM gitpod/workspace-full + +USER gitpod + +# Install custom tools, runtime, etc. using apt-get +# For example, the command below would install "bastet" - a command line tetris clone: +# +# RUN sudo apt-get -q update && \ +# sudo apt-get install -yq bastet && \ +# sudo rm -rf /var/lib/apt/lists/* +# +# More information: https://www.gitpod.io/docs/config-docker/ diff --git a/.gitpod.yml b/.gitpod.yml new file mode 100644 index 0000000..b94f769 --- /dev/null +++ b/.gitpod.yml @@ -0,0 +1,14 @@ +image: + file: .gitpod.Dockerfile + +# List the ports you want to expose and what to do when they are served. See https://www.gitpod.io/docs/config-ports/ +ports: + - port: 3000 + onOpen: open-preview + +# List the start up tasks. You can start them in parallel in multiple terminals. See https://www.gitpod.io/docs/config-start-tasks/ +tasks: + - init: composer install + command: composer dump-autoload + - command: cp .env.example .env + - command: php artisan dusk diff --git a/tests/DuskTestCase.php b/tests/DuskTestCase.php index b217c13..2fa6b82 100644 --- a/tests/DuskTestCase.php +++ b/tests/DuskTestCase.php @@ -33,20 +33,15 @@ protected function driver() $access_key = env('LT_ACCESS_KEY'); $url = "https://".$username.":".$access_key."@hub.lambdatest.com/wd/hub"; - return RemoteWebDriver::create($url, - DesiredCapabilities::chrome() - ->setCapability("platform", "win10") - ->setCapability("browserName", "chrome") - ->setCapability("version", "71.0") - ->setCapability("resolution", "1024x768") - ->setCapability("build", "LaravelDusk Build") - ->setCapability("name", "LaravelDusk Test") - ->setCapability("network", true) - ->setCapability("video", true) - ->setCapability("visual", true) - ->setCapability("console", true) - ->setCapability("tunnel", false) - ); + $capabilities = array( + "build" => "LaravelDusk Build", + "name" => "LaravelDusk Build", + "platform" => "Windows 10", + "browserName" => "Chrome", + "version" => "latest" + ); + + return RemoteWebDriver::create($url,$capabilities); } - + } From 01fabf8cbac462028c8eae0fa499618a3141ee2b Mon Sep 17 00:00:00 2001 From: Sirajuddin Khan Date: Thu, 10 Dec 2020 22:33:06 +0000 Subject: [PATCH 2/2] updated gitpod yml --- .gitignore | 1 + .gitpod.yml | 4 +--- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index c41a91f..2798a32 100644 --- a/.gitignore +++ b/.gitignore @@ -29,6 +29,7 @@ storage/*.key .env Homestead.yaml Homestead.json +*.lock # Rocketeer PHP task runner and deployment package. https://github.com/rocketeers/rocketeer .rocketeer/ diff --git a/.gitpod.yml b/.gitpod.yml index b94f769..aecf5e4 100644 --- a/.gitpod.yml +++ b/.gitpod.yml @@ -9,6 +9,4 @@ ports: # List the start up tasks. You can start them in parallel in multiple terminals. See https://www.gitpod.io/docs/config-start-tasks/ tasks: - init: composer install - command: composer dump-autoload - - command: cp .env.example .env - - command: php artisan dusk + command: composer dump-autoload && cp .env.example .env && php artisan dusk