@@ -148,6 +148,22 @@ describe("qa-otel-smoke receiver bounds", () => {
|
148 | 148 | expect(() => testing.parseArgs(args)).toThrow(`${flag} requires a value`); |
149 | 149 | }); |
150 | 150 | |
| 151 | +it("rejects duplicate OTEL smoke CLI options", () => { |
| 152 | +const duplicateCases = [ |
| 153 | +["--collector", ["--collector", "local", "--collector", "docker"]], |
| 154 | +["--logs-exporter", ["--logs-exporter", "otlp", "--logs-exporter", "stdout"]], |
| 155 | +["--output-dir", ["--output-dir", ".artifacts/one", "--output-dir", ".artifacts/two"]], |
| 156 | +["--provider-mode", ["--provider-mode", "mock-openai", "--provider-mode", "live-frontier"]], |
| 157 | +["--scenario", ["--scenario", "custom-one", "--scenario", "custom-two"]], |
| 158 | +["--model", ["--model", "openai/gpt-5.5", "--model", "openai/gpt-5.4"]], |
| 159 | +["--alt-model", ["--alt-model", "openai/gpt-5.5", "--alt-model", "openai/gpt-5.4"]], |
| 160 | +] satisfies Array<[string, string[]]>; |
| 161 | + |
| 162 | +for (const [flag, args] of duplicateCases) { |
| 163 | +expect(() => testing.parseArgs(args), flag).toThrow(`${flag} was provided more than once`); |
| 164 | +} |
| 165 | +}); |
| 166 | + |
151 | 167 | it("selects the matching scenario for the requested log exporter", () => { |
152 | 168 | expect(testing.parseArgs(["--logs-exporter", "otlp"]).scenarioId).toBe("otel-trace-smoke"); |
153 | 169 | expect(testing.parseArgs(["--logs-exporter", "stdout"]).scenarioId).toBe( |
|