Skip to content

Test against the init and builder images the checkout builds - #2180

Closed
MayCXC wants to merge 5 commits into
apple:mainfrom
MayCXC:integration-init-load-ordering
Closed

Test against the init and builder images the checkout builds#2180
MayCXC wants to merge 5 commits into
apple:mainfrom
MayCXC:integration-init-load-ordering

Conversation

@MayCXC

@MayCXC MayCXC commented Aug 27, 2026

Copy link
Copy Markdown

Type of Change

  • Bug fix
  • New feature
  • Breaking change
  • Documentation update

Motivation and Context

Five defects in make integration, all of which let a run report a pass about something other than what the checkout built.

The built init image is cleared before the tests see it. make integration clears the application data directory after init-block has already loaded the freshly built init image, so a run against a dedicated APP_ROOT tested the runtime's default init image instead of the one the editable containerization checkout produced. Features that live in the guest agent then fail their tests with no hint that the guest under test was the wrong one. The saved tar stays in the repository's bin directory and the integration recipe loads it after its own system start, once the data directory clearing is behind it; init-block keeps its own load so building the init image alone still refreshes the running store.

init-block cannot answer the kernel prompt. install-init.sh starts the system to load the init image it built, and a start against a data directory with no configured kernel asks on stdin whether to install one. The integration path runs this from make with no terminal, so the question fails the read and init-block exits before a single test begins. It passes --enable-kernel-install the way the integration recipe's own start already does, so the answer is the flag instead of a prompt.

A locally built builder image exists in no registry, the position the editable init image is in, so the recipe lands bin/builder.tar into the store the tests see the same way it lands bin/init.tar, and a fixture's builder start finds the image the configuration names instead of reaching for a registry that does not carry it.

The network suite pulls mid-run. It runs a python http.server, and pulling that image from Docker Hub in the middle of the concurrent pass put a registry round trip and its rate limits inside the test's readiness window. It is warmed with the other suite images now, so the pull happens once, before the load.

The default scratch root was not ignored. The integration recipe defaults SCRATCH_ROOT to .test-scratch under the repository so the builder can reach build contexts, and nothing ignored it, so an interrupted run's scratch trees were one git add away from a commit.

Testing

  • Tested locally
  • Added/updated tests
  • Added/updated docs

make integration against a dedicated APP_ROOT runs the built init image, starts without a terminal, and finds the built builder image. Integration suite: 397 passed. Unit suite: 772 passed. make fmt, make check clean.

MayCXC added 5 commits August 27, 2026 20:16
make integration clears the application data directory after init-block
has already loaded the freshly built init image, so a run against a
dedicated APP_ROOT tested the runtime's default init image instead of
the one the editable containerization checkout produced. Features that
live in the guest agent then fail their tests with no hint that the
guest under test was the wrong one.

Keep the saved tar in the repository's bin directory and load it from
the integration recipe after its own system start, once the data
directory clearing is behind it. init-block keeps its own load so
building the init image alone still refreshes the running store.
install-init.sh starts the system to load the init image it built, and
a start against a data directory with no configured kernel asks on
stdin whether to install one. The integration path runs this from make
with no terminal, so the question fails the read and init-block exits
before a single test begins. Pass --enable-kernel-install the way the
integration recipe's own start already does, so the answer is the flag
instead of a prompt.
The integration recipe defaults SCRATCH_ROOT to .test-scratch under the
repository so the builder can reach build contexts, and nothing ignored
it, so an interrupted run's scratch trees were one git add away from a
commit.
A locally built builder image exists in no registry, the position the
editable init image is in, so the recipe lands bin/builder.tar into the
store the tests see the same way it lands bin/init.tar, and a fixture's
builder start finds the image the configuration names instead of
reaching for a registry that does not carry it.
The network suite runs a python http.server; pulling its image from
Docker Hub in the middle of the concurrent pass put a registry round
trip and its rate limits inside the test's readiness window. Warmed
with the other suite images, the pull happens once, before the load.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants