@@ -5,7 +5,8 @@ workflows:
5
5
jobs :
6
6
- lint
7
7
- test-behat
8
- - test-phpunit
8
+ - test-phpunit-74
9
+ - test-phpunit-82
9
10
nightly :
10
11
triggers :
11
12
- schedule :
20
21
lint :
21
22
working_directory : ~/pantheon-systems/wp-native-php-sessions
22
23
docker :
23
- - image : quay.io/pantheon-public/build-tools-ci:6.x
24
+ - image : quay.io/pantheon-public/build-tools-ci:8.x-php8.2
24
25
steps :
25
26
- checkout
26
27
- restore_cache :
@@ -39,48 +40,48 @@ jobs:
39
40
working_directory : ~/pantheon-systems/wp-native-php-sessions
40
41
parallelism : 1
41
42
docker :
42
- - image : quay.io/pantheon-public/build-tools-ci:6.x
43
+ - image : quay.io/pantheon-public/build-tools-ci:8.x-php8.2
43
44
steps :
44
- - checkout
45
- - restore_cache :
46
- keys :
47
- - test-behat-dependencies-{{ checksum "composer.json" }}
48
- - run : composer install -n --prefer-dist
49
- - save_cache :
50
- key : test-behat-dependencies-{{ checksum "composer.json" }}
51
- paths :
52
- - vendor
53
- - run : echo $(openssl rand -hex 8) > /tmp/WORDPRESS_ADMIN_PASSWORD
54
- - run : |
55
- echo 'export TERMINUS_ENV=ci-$CIRCLE_BUILD_NUM' >> $BASH_ENV
56
- echo 'export TERMINUS_SITE=wp-native-php-sessions' >> $BASH_ENV
57
- echo 'export SITE_ENV=wp-native-php-sessions.ci-$CIRCLE_BUILD_NUM' >> $BASH_ENV
58
- echo 'export WORDPRESS_ADMIN_USERNAME=pantheon' >> $BASH_ENV
59
- echo 'export [email protected] ' >> $BASH_ENV
60
- echo 'export WORDPRESS_ADMIN_PASSWORD=$(cat /tmp/WORDPRESS_ADMIN_PASSWORD)' >> $BASH_ENV
61
- source $BASH_ENV
62
- - run : echo "StrictHostKeyChecking no" >> "$HOME/.ssh/config"
63
- - run : |
64
- if [ -z "$GITHUB_TOKEN" ]; then
65
- echo "GITHUB_TOKEN environment variables missing; assuming unauthenticated build"
66
- exit 0
67
- fi
68
- echo "Setting GitHub OAuth token with suppressed ouput"
69
- {
70
- composer config -g github-oauth.github.com $GITHUB_TOKEN
71
- } &> /dev/null
72
- - run : |
73
- if [ -z "$TERMINUS_TOKEN" ]; then
74
- echo "TERMINUS_TOKEN environment variables missing; assuming unauthenticated build"
75
- exit 0
76
- fi
77
- terminus auth:login --machine-token=$TERMINUS_TOKEN
78
- - run : ./bin/behat-prepare.sh
79
- - run : ./bin/behat-test.sh --strict
80
- - run :
81
- command : ./bin/behat-cleanup.sh
82
- when : always
83
- test-phpunit :
45
+ - checkout
46
+ - restore_cache :
47
+ keys :
48
+ - test-behat-dependencies-{{ checksum "composer.json" }}
49
+ - run : composer install -n --prefer-dist
50
+ - save_cache :
51
+ key : test-behat-dependencies-{{ checksum "composer.json" }}
52
+ paths :
53
+ - vendor
54
+ - run : echo $(openssl rand -hex 8) > /tmp/WORDPRESS_ADMIN_PASSWORD
55
+ - run : |
56
+ echo 'export TERMINUS_ENV=ci-$CIRCLE_BUILD_NUM' >> $BASH_ENV
57
+ echo 'export TERMINUS_SITE=wp-native-php-sessions' >> $BASH_ENV
58
+ echo 'export SITE_ENV=wp-native-php-sessions.ci-$CIRCLE_BUILD_NUM' >> $BASH_ENV
59
+ echo 'export WORDPRESS_ADMIN_USERNAME=pantheon' >> $BASH_ENV
60
+ echo 'export [email protected] ' >> $BASH_ENV
61
+ echo 'export WORDPRESS_ADMIN_PASSWORD=$(cat /tmp/WORDPRESS_ADMIN_PASSWORD)' >> $BASH_ENV
62
+ source $BASH_ENV
63
+ - run : echo "StrictHostKeyChecking no" >> "$HOME/.ssh/config"
64
+ - run : |
65
+ if [ -z "$GITHUB_TOKEN" ]; then
66
+ echo "GITHUB_TOKEN environment variables missing; assuming unauthenticated build"
67
+ exit 0
68
+ fi
69
+ echo "Setting GitHub OAuth token with suppressed ouput"
70
+ {
71
+ composer config -g github-oauth.github.com $GITHUB_TOKEN
72
+ } &> /dev/null
73
+ - run : |
74
+ if [ -z "$TERMINUS_TOKEN" ]; then
75
+ echo "TERMINUS_TOKEN environment variables missing; assuming unauthenticated build"
76
+ exit 0
77
+ fi
78
+ terminus auth:login --machine-token=$TERMINUS_TOKEN
79
+ - run : ./bin/behat-prepare.sh
80
+ - run : ./bin/behat-test.sh --strict
81
+ - run :
82
+ command : ./bin/behat-cleanup.sh
83
+ when : always
84
+ test-phpunit-74 :
84
85
working_directory : ~/pantheon-systems/wp-native-php-sessions
85
86
docker :
86
87
- image : circleci/php:7.4-node-browsers
@@ -92,10 +93,10 @@ jobs:
92
93
- checkout
93
94
- restore_cache :
94
95
keys :
95
- - test-phpunit-dependencies-{{ checksum "composer.json" }}
96
+ - test-phpunit-74- dependencies-{{ checksum "composer.json" }}
96
97
- run : composer install -n --prefer-dist
97
98
- save_cache :
98
- key : test-phpunit-dependencies-{{ checksum "composer.json" }}
99
+ key : test-phpunit-74- dependencies-{{ checksum "composer.json" }}
99
100
paths :
100
101
- vendor
101
102
- run :
@@ -118,3 +119,41 @@ jobs:
118
119
rm -rf $WP_TESTS_DIR $WP_CORE_DIR
119
120
bash bin/install-wp-tests.sh wordpress_test root '' 127.0.0.1 nightly true
120
121
composer phpunit
122
+ test-phpunit-82 :
123
+ working_directory : ~/pantheon-systems/wp-native-php-sessions
124
+ docker :
125
+ - image : cimg/php:8.2.0
126
+ - image : circleci/mariadb:10.3
127
+ environment :
128
+ - WP_TESTS_DIR : " /tmp/wordpress-tests-lib"
129
+ - WP_CORE_DIR : " /tmp/wordpress/"
130
+ steps :
131
+ - checkout
132
+ - restore_cache :
133
+ keys :
134
+ - test-phpunit-82-dependencies-{{ checksum "composer.json" }}
135
+ - run : composer install -n --prefer-dist
136
+ - save_cache :
137
+ key : test-phpunit-82-dependencies-{{ checksum "composer.json" }}
138
+ paths :
139
+ - vendor
140
+ - run :
141
+ name : " Install Extras"
142
+ command : |
143
+ sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 4EB27DB2A3B88B8B
144
+ sudo apt-get update
145
+ sudo apt-get install subversion
146
+ sudo apt-get install -y libmagickwand-dev --no-install-recommends
147
+ yes '' | sudo pecl install imagick || true
148
+ sudo docker-php-ext-enable imagick
149
+ sudo docker-php-ext-install mysqli
150
+ sudo apt-get install mariadb-client-10.6
151
+ - run :
152
+ name : " Run Tests"
153
+ command : |
154
+ bash bin/install-wp-tests.sh wordpress_test root '' 127.0.0.1 latest
155
+ composer phpunit
156
+ WP_MULTISITE=1 composer phpunit
157
+ rm -rf $WP_TESTS_DIR $WP_CORE_DIR
158
+ bash bin/install-wp-tests.sh wordpress_test root '' 127.0.0.1 nightly true
159
+ composer phpunit
0 commit comments