Skip to content
This repository has been archived by the owner on Apr 7, 2024. It is now read-only.

Add cypress verify to project command #344

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion src/Command/ProjectCommands.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public function projectTestCypress(array $args)

// Clean up environment.
$this->deleteTestUsers();

return $result;
}

Expand Down Expand Up @@ -99,6 +99,14 @@ protected function installNpmDependencies(): void
if ($result->getExitCode() !== 0) {
throw new \RuntimeException('Failed to install test dependencies');
}

$this->io()->say('Verifying Cypress...');
$verify = $this->taskExec('CYPRESS_baseUrl="http://$DKTL_PROXY_DOMAIN" npx cypress verify')
->dir(self::TESTS_DIR)
->run();
if ($verify && $verify->getExitCode() !== 0) {
throw new \RuntimeException('Failed to verify cypress');
}
}

/**
Expand Down