mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-10-05 15:09:42 +02:00
fix(docker): merge-time fixes for #492
- test: the complete-identity case now checks the combined agentImageBuildArgPairs() argv on both producers, so the manual build-agent-image.mjs path cannot drop the identity unnoticed - both producers: GIT_IDENTITY_BUILD_ARGS carries the mirror/parity warning its gh/az neighbour has - the partial-identity error names CODEMAN_AGENT_IMAGE_GIT_USER_NAME and CODEMAN_AGENT_IMAGE_GIT_USER_EMAIL; test regex follows - wiki Docker-Cases: mention the identity variables next to the gh/az switches Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -172,6 +172,9 @@ describe('Git identity in the agent image: both producers pass the same settings
|
||||
expect(mjsGitIdentityPairs(identity)).toEqual(expected);
|
||||
expect(tsGitIdentityPairs({})).toEqual([]);
|
||||
expect(mjsGitIdentityPairs({})).toEqual([]);
|
||||
// The combined argv, not just the helper: the manual build path could drop the identity otherwise.
|
||||
expect(tsPairs(identity)).toEqual(mjsPairs(CATALOG, identity));
|
||||
expect(tsPairs(identity)).toEqual(expect.arrayContaining(expected));
|
||||
});
|
||||
|
||||
it('refuses a partial identity in both build paths', () => {
|
||||
@@ -179,8 +182,9 @@ describe('Git identity in the agent image: both producers pass the same settings
|
||||
{ CODEMAN_AGENT_IMAGE_GIT_USER_NAME: 'Ada Lovelace' },
|
||||
{ CODEMAN_AGENT_IMAGE_GIT_USER_EMAIL: 'ada@example.com' },
|
||||
]) {
|
||||
expect(() => tsGitIdentityPairs(identity)).toThrow(/Git user name and email/);
|
||||
expect(() => mjsGitIdentityPairs(identity)).toThrow(/Git user name and email/);
|
||||
const named = /CODEMAN_AGENT_IMAGE_GIT_USER_NAME and CODEMAN_AGENT_IMAGE_GIT_USER_EMAIL must both be set/;
|
||||
expect(() => tsGitIdentityPairs(identity)).toThrow(named);
|
||||
expect(() => mjsGitIdentityPairs(identity)).toThrow(named);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user