Skip to content

fix(reports): avoid quoting string identifiers in template builder and add unit tests - #371

Merged
max-ostapenko merged 1 commit into
mainfrom
fix/reports-template-builder-and-tests
Nov 13, 2026
Merged

max-ostapenko merged 1 commit into
mainfrom
fix/reports-template-builder-and-tests

Conversation

@max-ostapenko

Copy link
Copy Markdown
Contributor

Summary

  • Fix DataformTemplateBuilder.create (resolveVariable) so deferred string placeholders are returned raw instead of wrapped in extra single quotes ('...'').
  • Add input validation to DataformTemplateBuilder.create, HTTPArchiveReports.getReport, and HTTPArchiveReports.getMetric, and guard listReports() when _reports is absent.
  • Export DataformTemplateBuilder and add a unit test suite (tests/reports.test.js) using Node's built-in test runner that verifies template resolution, report/metric validation, and SQL compilation for all configured metrics.
  • Add npm test to package.json and the GitHub Actions CI workflow (.github/workflows/ci.yaml).

@max-ostapenko
max-ostapenko merged commit e7ad275 into main Nov 13, 2026
6 checks passed
@max-ostapenko
max-ostapenko deleted the fix/reports-template-builder-and-tests branch November 13, 2026 18:15
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.

1 participant