Skip to content

Commit

Permalink
! try to get some failure output
Browse files Browse the repository at this point in the history
  • Loading branch information
Spuds committed Mar 28, 2024
1 parent 5c8f3df commit 09c2357
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/setup-selenium.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,9 @@ echo "Installing Browser"
#
CHROME_VERSION='112.0.5615.49-1' #'110.0.5481.100-1' # '91.0.4472.114-1'

wget https://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-stable_${CHROME_VERSION}_amd64.deb
sudo dpkg -i google-chrome-stable_${CHROME_VERSION}_amd64.deb
#wget -v -O /tmp/google-chrome-stable_${CHROME_VERSION}_amd64.deb https://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-stable_${CHROME_VERSION}_amd64.deb
#curl -L -o /tmp/chrome.deb https://dl.google.com/linux/chrome/deb/pool/main/g/google-chrome-stable/google-chrome-stable_${CHROME_VERSION}_amd64.deb
#sudo dpkg -i /tmp/chrome.deb

# Download Chrome Driver
echo "Downloading chromedriver"
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,11 @@ jobs:
run: .github/setup-elkarte.sh $DB $PHP_VERSION
working-directory: ./elkarte

- name: Setup Chrome
uses: browser-actions/setup-chrome@v1
with:
chrome-version: 113

- name: Run Unit Tests
env:
DB: ${{ matrix.db }}
Expand Down
6 changes: 6 additions & 0 deletions sources/Subs.php
Original file line number Diff line number Diff line change
Expand Up @@ -585,6 +585,9 @@ function redirectexit($setLocation = '')
{
global $db_show_debug;

// Note to developers. The testbed will add the following, allowing phpunit test returns
//if (defined("PHPUNITBOOTSTRAP") && defined("STDIN")){return $setLocation;}

// Send headers, call integration, do maintance
Headers::instance()
->removeHeader('all')
Expand Down Expand Up @@ -691,6 +694,9 @@ function obExit($header = null, $do_footer = null, $from_index = false, $from_fa
// Hand off the output to the portal, etc. we're integrated with.
call_integration_hook('integrate_exit', [$do_footer]);

// Note to developers. The testbed will add the following, allowing phpunit test returns

Check warning on line 697 in sources/Subs.php

View check run for this annotation

Codecov / codecov/patch

sources/Subs.php#L697

Added line #L697 was not covered by tests
//if (defined("PHPUNITBOOTSTRAP") && defined("STDIN")){return;}

Check warning on line 699 in sources/Subs.php

View check run for this annotation

Codecov / codecov/patch

sources/Subs.php#L699

Added line #L699 was not covered by tests
// Don't exit if we're coming from index.php; that will pass through normally.
if (!$from_index)
{
Expand Down

0 comments on commit 09c2357

Please sign in to comment.