Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/user_saml.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.drone.yml20
-rw-r--r--tests/integration/features/bootstrap/FeatureContext.php17
2 files changed, 19 insertions, 18 deletions
diff --git a/.drone.yml b/.drone.yml
index 4db07b88..0bb6979d 100644
--- a/.drone.yml
+++ b/.drone.yml
@@ -70,22 +70,20 @@ steps:
- cd tests/unit/
- phpunit --configuration phpunit.xml
- name: integration-tests-master
- image: nextcloudci/user_saml_shibboleth-php7:user_saml_shibboleth_php7-5
+ image: nextcloudci/user_saml_shibboleth-php7.2:user_saml_shibboleth_php7.2-1
environment:
CORE_BRANCH: master
commands:
- /start.sh &
- sleep 3
- - scl enable rh-php70 bash
- rm -rf /var/www/html
- cd /var/www/
- git clone --depth 1 -b $CORE_BRANCH https://github.com/nextcloud/server html
- cd /var/www/html && git submodule update --init
- cd /var/www/html/apps/ && git clone -b $DRONE_BRANCH https://github.com/nextcloud/user_saml.git
- - php /var/www/html/occ maintenance:install --database sqlite --admin-pass password
- - php /var/www/html/occ app:enable user_saml
+ - scl enable rh-php72 "bash -c 'php /var/www/html/occ maintenance:install --database sqlite --admin-pass password; php /var/www/html/occ app:enable user_saml'"
- chown -R apache:apache /var/www/html/
- - cd /var/www/html/apps/user_saml/tests/integration && vendor/bin/behat
+ - scl enable rh-php72 "bash -c 'cd /var/www/html/apps/user_saml/tests/integration && vendor/bin/behat'"
trigger:
branch:
@@ -121,16 +119,14 @@ steps:
commands:
- /start.sh &
- sleep 3
- - scl enable rh-php70 bash
- rm -rf /var/www/html
- cd /var/www/
- git clone --depth 1 -b $CORE_BRANCH https://github.com/nextcloud/server html
- cd /var/www/html && git submodule update --init
- cd /var/www/html/apps/ && git clone -b $DRONE_BRANCH https://github.com/nextcloud/user_saml.git
- - php /var/www/html/occ maintenance:install --database sqlite --admin-pass password
- - php /var/www/html/occ app:enable user_saml
+ - scl enable rh-php70 "bash -c 'php /var/www/html/occ maintenance:install --database sqlite --admin-pass password; php /var/www/html/occ app:enable user_saml'"
- chown -R apache:apache /var/www/html/
- - cd /var/www/html/apps/user_saml/tests/integration && vendor/bin/behat
+ - scl enable rh-php70 "bash -c 'cd /var/www/html/apps/user_saml/tests/integration && vendor/bin/behat'"
trigger:
branch:
@@ -166,16 +162,14 @@ steps:
commands:
- /start.sh &
- sleep 3
- - scl enable rh-php70 bash
- rm -rf /var/www/html
- cd /var/www/
- git clone --depth 1 -b $CORE_BRANCH https://github.com/nextcloud/server html
- cd /var/www/html && git submodule update --init
- cd /var/www/html/apps/ && git clone -b $DRONE_BRANCH https://github.com/nextcloud/user_saml.git
- - php /var/www/html/occ maintenance:install --database sqlite --admin-pass password
- - php /var/www/html/occ app:enable user_saml
+ - scl enable rh-php70 "bash -c 'php /var/www/html/occ maintenance:install --database sqlite --admin-pass password; php /var/www/html/occ app:enable user_saml'"
- chown -R apache:apache /var/www/html/
- - cd /var/www/html/apps/user_saml/tests/integration && vendor/bin/behat
+ - scl enable rh-php70 "bash -c 'cd /var/www/html/apps/user_saml/tests/integration && vendor/bin/behat'"
trigger:
branch:
diff --git a/tests/integration/features/bootstrap/FeatureContext.php b/tests/integration/features/bootstrap/FeatureContext.php
index c1656da1..c3460582 100644
--- a/tests/integration/features/bootstrap/FeatureContext.php
+++ b/tests/integration/features/bootstrap/FeatureContext.php
@@ -45,6 +45,8 @@ class FeatureContext implements Context {
'track_redirects' => true,
],
]);
+
+
}
/** @AfterScenario */
@@ -56,7 +58,8 @@ class FeatureContext implements Context {
foreach($users as $user) {
shell_exec(
sprintf(
- 'sudo -u apache /opt/rh/rh-php70/root/usr/bin/php %s user:delete %s',
+ 'sudo -u apache %s %s user:delete %s',
+ PHP_BINARY,
__DIR__ . '/../../../../../../occ',
$user
)
@@ -66,7 +69,8 @@ class FeatureContext implements Context {
foreach($this->changedSettings as $setting) {
shell_exec(
sprintf(
- 'sudo -u apache /opt/rh/rh-php70/root/usr/bin/php %s config:app:delete user_saml %s',
+ 'sudo -u apache %s %s config:app:delete user_saml %s',
+ PHP_BINARY,
__DIR__ . '/../../../../../../occ',
$setting
)
@@ -86,7 +90,8 @@ class FeatureContext implements Context {
$this->changedSettings[] = $settingName;
shell_exec(
sprintf(
- 'sudo -u apache /opt/rh/rh-php70/root/usr/bin/php %s config:app:set --value="%s" user_saml %s',
+ 'sudo -u apache %s %s config:app:set --value="%s" user_saml %s',
+ PHP_BINARY,
__DIR__ . '/../../../../../../occ',
$value,
$settingName
@@ -235,7 +240,8 @@ class FeatureContext implements Context {
public function aLocalUserWithUidExists($uid) {
shell_exec(
sprintf(
- 'sudo -u apache OC_PASS=password /opt/rh/rh-php70/root/usr/bin/php %s user:add %s --display-name "Default displayname of '.$uid.'" --password-from-env',
+ 'sudo -u apache OC_PASS=password%s %s user:add %s --display-name "Default displayname of '.$uid.'" --password-from-env',
+ PHP_BINARY,
__DIR__ . '/../../../../../../occ',
$uid
)
@@ -251,7 +257,8 @@ class FeatureContext implements Context {
public function theLastLoginTimestampOfShouldNotBeEmpty($uid) {
$response = shell_exec(
sprintf(
- 'sudo -u apache OC_PASS=password /opt/rh/rh-php70/root/usr/bin/php %s user:lastseen %s',
+ 'sudo -u apache OC_PASS=password %s %s user:lastseen %s',
+ PHP_BINARY,
__DIR__ . '/../../../../../../occ',
$uid
)