File tree Expand file tree Collapse file tree 1 file changed +20
-2
lines changed Expand file tree Collapse file tree 1 file changed +20
-2
lines changed Original file line number Diff line number Diff line change 11# syntax=docker/dockerfile:1.7
2- FROM --platform=$BUILDPLATFORM scratch AS build
2+ FROM --platform=$BUILDPLATFORM scratch AS build-wp
33ARG WP_GIT_REF
44ADD https://github.com/WordPress/WordPress.git#${WP_GIT_REF} /wp
55COPY extra/ /wp/
66
7+ FROM alpine:3.21.3@sha256:a8560b36e8b8210634f77d9f7f9efd7ffa463e380b75e2e74aff4511df3ef88c AS build-wptl
8+ ARG WP_GIT_REF
9+ RUN \
10+ apk add --no-cache curl subversion && \
11+ if [ -z "${WP_GIT_REF}" ]; then \
12+ TESTS_TAG=trunk; \
13+ else \
14+ TESTS_TAG="tags/${WP_GIT_REF}" ; \
15+ fi && \
16+ svn co --quiet --ignore-externals "https://develop.svn.wordpress.org/${TESTS_TAG}/tests/phpunit/includes/" /wordpress-tests-lib/includes && \
17+ svn co --quiet --ignore-externals "https://develop.svn.wordpress.org/${TESTS_TAG}/tests/phpunit/data/" /wordpress-tests-lib/data && \
18+ curl -sL "https://develop.svn.wordpress.org/${TESTS_TAG}/wp-tests-config-sample.php" | \
19+ sed \
20+ "s/youremptytestdbnamehere/wordpress_test/; s/yourusernamehere/wordpress/; s/yourpasswordhere/wordpress/; s/localhost/database/; s:dirname( __FILE__ ) . '/src/':'/wp/':" \
21+ > /wordpress-tests-lib/wp-tests-config.php
22+
723FROM ghcr.io/automattic/vip-container-images/helpers:v1@sha256:bc2beca042ce7c47e2b737920c77248f4a6c25cc7e137bf9de6944af8a68701c AS helpers
824FROM busybox:stable-musl@sha256:52931c5795db81b02f89211b300630477f851870b5504d6883c7c38f99f4e692
9- COPY --from=build --link /wp /wp
25+ ENV WP_TESTS_DIR=/wp/wp-content/wordpress-tests-lib
26+ COPY --from=build-wp --link /wp /wp
27+ COPY --from=build-wptl /wordpress-tests-lib /wp/wp-content/wordpress-tests-lib
1028COPY --link dev-tools /dev-tools
1129COPY --link dev-tools /dev-tools-orig
1230COPY --link scripts /scripts
You can’t perform that action at this time.
0 commit comments