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

Test install nextcloud directly #1393

Merged
merged 5 commits into from
Oct 24, 2023
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
76 changes: 54 additions & 22 deletions .github/workflows/uitests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ permissions:
jobs:
build-and-test:
name: Build and Test
runs-on: macOS-latest
runs-on: macos-latest
if: github.event.pull_request.draft == false

strategy:
Expand Down Expand Up @@ -55,33 +55,66 @@ jobs:
restore-keys: |
${{ runner.os }}-pods-

- uses: actions/cache@v3
- name: Set up php 8.2
uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2
if: matrix.test-branches != 'stable23'
with:
path: SourcePackages
key: ${{ runner.os }}-spm-${{ hashFiles('NextcloudTalk.xcworkspace/xcshareddata/swiftpm/Package.resolved') }}
restore-keys: |
${{ runner.os }}-spm-

- name: Install docker
run: |
brew install docker
colima start
php-version: 8.2
# https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation
extensions: apcu, bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, pgsql, pdo_pgsql
coverage: none
ini-file: development
# Temporary workaround for missing pcntl_* in PHP 8.3: ini-values: apc.enable_cli=on
ini-values: apc.enable_cli=on, disable_functions=
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Set up php 8.0
uses: shivammathur/setup-php@c5fc0d8281aba02c7fda07d3a70cc5371548067d # v2
if: matrix.test-branches == 'stable23'
with:
php-version: 8.0
# https://docs.nextcloud.com/server/stable/admin_manual/installation/source_installation.html#prerequisites-for-manual-installation
extensions: apcu, bz2, ctype, curl, dom, fileinfo, gd, iconv, intl, json, libxml, mbstring, openssl, pcntl, posix, session, simplexml, xmlreader, xmlwriter, zip, zlib, pgsql, pdo_pgsql
coverage: none
ini-file: development
# Temporary workaround for missing pcntl_* in PHP 8.3: ini-values: apc.enable_cli=on
ini-values: apc.enable_cli=on, disable_functions=
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Checkout server
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2
with:
submodules: true
repository: nextcloud/server
path: server
ref: ${{ matrix.test-branches }}

- name: Create docker test server
run: |
source ./ci-create-docker-server.sh
- name: Checkout Talk
uses: actions/checkout@8e5e7e5ab8b370d6c329ec480221332ada57f0ab # v3.5.2
with:
repository: nextcloud/spreed
path: server/apps/spreed
ref: ${{ matrix.test-branches }}

- name: Set up dependencies talk-ios
run: |
pod install
- name: Set up production dependencies
working-directory: server/apps/spreed
run: composer i --no-dev

- name: Wait for server
- name: Set up Nextcloud
run: |
source ./ci-wait-for-server.sh
mkdir server/data
./server/occ maintenance:install --verbose --database=sqlite --database-name=nextcloud --database-host=127.0.0.1 --database-user=root --database-pass=rootpassword --admin-user admin --admin-pass admin
./server/occ config:system:set hashing_default_password --value=true --type=boolean
./server/occ config:system:set memcache.local --value="\\OC\\Memcache\\APCu"
./server/occ config:system:set memcache.distributed --value="\\OC\\Memcache\\APCu"
./server/occ app:enable --force spreed
PHP_CLI_SERVER_WORKERS=3 php -S localhost:8080 -t server/ &

- name: Install talk
- name: Set up dependencies talk-ios
run: |
source ./ci-install-talk.sh
pod install

- name: Build & Test NextcloudTalk iOS
run: |
Expand All @@ -91,7 +124,6 @@ jobs:
-test-iterations 3 \
-retry-tests-on-failure \
-resultBundlePath "testResult.xcresult" \
-clonedSourcePackagesDirPath SourcePackages \
| xcpretty

- name: Upload test results
Expand Down
10 changes: 1 addition & 9 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,7 @@ Podfile.lock
NextcloudTalk.xcodeproj/xcuserdata
NextcloudTalk.xcodeproj/xcshareddata
NextcloudTalk.xcworkspace/xcuserdata
NextcloudTalk.xcworkspace/xcshareddata
ThirdParty/WebRTC.xcframework
.DS_Store
testResult.xcresult

# Include the resolved spm configuration, so "Package.resolved" can be used for caching
NextcloudTalk.xcworkspace/**
!NextcloudTalk.xcworkspace/xcshareddata/
!NextcloudTalk.xcworkspace/xcshareddata/swiftpm
!NextcloudTalk.xcworkspace/xcshareddata/swiftpm/**

# Exclude SPM cache on CI
SourcePackages
1 change: 0 additions & 1 deletion .swiftlint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ identifier_name:
excluded:
- Pods
- ThirdParty
- SourcePackages
- NextcloudTalk/RLMSupport.swift

reporter: "xcode"
Expand Down
164 changes: 0 additions & 164 deletions NextcloudTalk.xcworkspace/xcshareddata/swiftpm/Package.resolved

This file was deleted.

Loading