diff --git a/scripts/run_image_contract.sh b/scripts/run_image_contract.sh index ba51c54..d36506d 100755 --- a/scripts/run_image_contract.sh +++ b/scripts/run_image_contract.sh @@ -121,11 +121,14 @@ docker run --detach \ --name "$llm_container_name" \ --network "$network_name" \ --network-alias compat-llm \ - --volume "$repo_root/scripts:/compat:ro" \ "$python_image" \ - python /compat/fake_llm.py --port 8080 --port-file /tmp/compat-port \ + python -c 'import time; time.sleep(3600)' \ >/dev/null llm_container_started=1 +docker cp "$repo_root/scripts/fake_llm.py" "$llm_container_name:/tmp/fake_llm.py" +docker exec --detach \ + "$llm_container_name" \ + python /tmp/fake_llm.py --port 8080 --port-file /tmp/compat-port for _ in $(seq 1 100); do if docker exec "$llm_container_name" wget -qO- http://127.0.0.1:8080/health >/dev/null 2>&1; then diff --git a/test/repository_test.rb b/test/repository_test.rb index 99e4919..8203f09 100644 --- a/test/repository_test.rb +++ b/test/repository_test.rb @@ -325,6 +325,8 @@ class RepositoryTest < Minitest::Test assert_includes probe, "ExactLiveContract.assert_authoritative_assistant_count!" refute_includes probe, "full_text.include?" assert_includes runner, "exact_live_contract.rb" + assert_includes runner, 'docker cp "$repo_root/scripts/fake_llm.py"' + refute_includes runner, '--volume "$repo_root/scripts:/compat:ro"' assert_includes runner, "OPENCODE_COMPAT_EVIDENCE_PATH" assert_includes runner, "OPENCODE_EXPECTED_VERSION" refute_match(/request_count.*-lt\s+1/, runner)