Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Add a summary for integration #666

Merged
merged 3 commits into from
Feb 8, 2025
Merged
Show file tree
Hide file tree
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
25 changes: 18 additions & 7 deletions .github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,16 +60,13 @@ jobs:
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
submodules: recursive
repository: nextcloud/server
ref: ${{ matrix.server-versions }}

- name: Checkout submodules
shell: bash
run: |
auth_header="$(git config --local --get http.https://github.com/.extraheader)"
git submodule sync --recursive
git -c "http.extraheader=$auth_header" -c protocol.version=2 submodule update --init --force --recursive --depth=1
cd build/integration && composer require --dev phpunit/phpunit:~9
- name: Set up integration dependencies
working-directory: build/integration
run: composer require --dev phpunit/phpunit:~9

- name: Checkout app
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
Expand Down Expand Up @@ -125,3 +122,17 @@ jobs:
if: always()
run: |
cat data/nextcloud.log

summary:
permissions:
contents: none
runs-on: ubuntu-latest-low
needs: [integration]

if: always()

name: integration-summary

steps:
- name: Summary status
run: if ${{ needs.integration.result != 'success' }}; then exit 1; fi
2 changes: 1 addition & 1 deletion lib/Operation.php
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ public function checkFileAccess(IStorage $storage, string $path, bool $isDir = f
$this->nestingLevel--;

if (!empty($match)) {
$e = new \RuntimeException('Access denied for path ' . $path . ' that is ' . ($isDir ? '' : 'not ') . 'a directory and matches rules: ' . json_encode($match));
$e = new \RuntimeException('Access denied for path ' . $path . ' that is ' . ($isDir ? '' : 'not ') . 'a directory and matches rules: ' . (string)json_encode($match));
$this->logger->debug($e->getMessage(), ['exception' => $e]);
// All Checks of one operation matched: prevent access
throw new ForbiddenException('Access denied by access control', false);
Expand Down