Skip to content

Commit 6e6ca1c

Browse files
authored
Clean and speed up test CI setup a bit (#9726)
- Don't download `vim-nox` as part of container setup. It adds time to the container setup and occasionally has warnings. If someone has a use case for it, they can always download it themselves. - Use a partial treeless clone for cloning Flutter since we only need the blobs of the latest commit on the branch. - Prevent the code excerpter from descending into all generated platform specific folders for generating fragments. - In `make test`, group the setup in the GitHub actions output to make it easier to visually parse.
1 parent 4f36a5c commit 6e6ca1c

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

Dockerfile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ RUN apt-get update && apt-get install -yq --no-install-recommends \
1212
lsof \
1313
make \
1414
unzip \
15-
vim-nox \
1615
xdg-user-dirs \
1716
&& rm -rf /var/lib/apt/lists/*
1817

@@ -32,7 +31,7 @@ ENV FLUTTER_ROOT=flutter
3231
ENV FLUTTER_BIN=flutter/bin
3332
ENV PATH="/flutter/bin:$PATH"
3433

35-
RUN git clone --branch $FLUTTER_BUILD_BRANCH --single-branch https://github.com/flutter/flutter /flutter/
34+
RUN git clone --branch $FLUTTER_BUILD_BRANCH --single-branch --filter=tree:0 https://github.com/flutter/flutter /flutter/
3635
VOLUME /flutter
3736

3837
# Set up Flutter

Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,10 +88,12 @@ emulate:
8888
# WARNING this can take a while to run!
8989
# Usage: `FLUTTER_BUILD_BRANCH=<channel> make test`
9090
test:
91+
@echo "::group::Setting up container"
9192
DOCKER_BUILDKIT=1 docker build --rm \
9293
--target tests \
9394
-t flt-test \
9495
--build-arg FLUTTER_BUILD_BRANCH=${FLUTTER_BUILD_BRANCH} .
96+
@echo "::endgroup::"
9597
docker run --rm --name flt-tests -t flt-test
9698

9799
# Stop long running tests

build.excerpt.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,11 @@ targets:
1010
exclude:
1111
- '**/.*/**'
1212
- '**/android/**'
13-
- '**/build/**'
1413
- '**/ios/**'
14+
- '**/linux/**'
15+
- '**/macos/**'
16+
- '**/windows/**'
17+
- '**/build/**'
1518
- '**/node_modules/**'
1619
- '**/*.jar'
1720
- '**/codelab_rebuild.yaml'

0 commit comments

Comments
 (0)