diff --git a/src/reporters/github/github.test.ts b/src/reporters/github/github.test.ts
index c2833e6..6d7edef 100644
--- a/src/reporters/github/github.test.ts
+++ b/src/reporters/github/github.test.ts
@@ -204,6 +204,29 @@ describe("buildViewModel", () => {
expect(vm.displayTestOriginExcluded[0].queryPreview).toBe("SELECT * FROM t");
});
+ test("multiple test-origin excluded queries each start a new bullet (trimBlocks glue)", () => {
+ // trimBlocks eats the newline after the row's trailing `{% endif %}`; without
+ // the `{{""}}` guard the next bullet glues onto the prior cost line ("cost 1- SELECT…").
+ const excluded = (hash: string, table: string) => ({
+ hash,
+ query: `SELECT "id" FROM "${table}"`,
+ formattedQuery: `SELECT "id" FROM "${table}"`,
+ nudges: [], tags: [], tableReferences: [],
+ optimization: { state: "no_improvement_found" as const, cost: 1, indexesUsed: [] },
+ });
+ const ctx = makeContext({
+ comparison: makeComparison({
+ testOriginExcluded: [excluded("t1", "sessions"), excluded("t2", "item_watches")],
+ }),
+ });
+ const output = renderTemplate(ctx);
+
+ expect(output).not.toMatch(/cost 1- /);
+ expect(output).toContain(
+ 'SELECT "id" FROM "sessions"
cost 1\n- SELECT "id" FROM "item_watches"',
+ );
+ });
+
test("new query without a recommendation is still listed (Site#3287 follow-up)", () => {
const ctx = makeContext({
comparison: makeComparison({
diff --git a/src/reporters/github/success.md.j2 b/src/reporters/github/success.md.j2
index 424e1a1..06b86cc 100644
--- a/src/reporters/github/success.md.j2
+++ b/src/reporters/github/success.md.j2
@@ -91,7 +91,7 @@
{{ displayTestOriginExcluded.length }} test-origin quer{{ "ies" if displayTestOriginExcluded.length != 1 else "y" }} excluded from the gate
{% for q in displayTestOriginExcluded %}
-- {{ q.queryPreview }}{% if q.costLabel %}
{{ q.costLabel }}{% endif %}
+- {{ q.queryPreview }}{% if q.costLabel %}
{{ q.costLabel }}{% endif %}{{""}}
{% endfor %}
{% endif %}