Skip to content

feat: sync tests#611

Merged
stephenamar-db merged 2 commits intodatabricks:masterfrom
He-Pin:tests
Feb 27, 2026
Merged

feat: sync tests#611
stephenamar-db merged 2 commits intodatabricks:masterfrom
He-Pin:tests

Conversation

@He-Pin
Copy link
Contributor

@He-Pin He-Pin commented Feb 27, 2026

Copilot AI review requested due to automatic review settings February 27, 2026 12:41
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR synchronizes test suites from upstream Google Jsonnet repositories and improves test error reporting. It adds a comprehensive sync script for keeping test suites in sync with upstream, updates error messages for better clarity, fixes YAML parsing behavior for empty/blank input, and enhances the test framework to collect and report all failures at once rather than stopping at the first failure.

Changes:

  • Added sync_test_suites.sh script to automate syncing test files from google/jsonnet and google/go-jsonnet repositories
  • Enhanced test failure reporting to collect and summarize all failures instead of failing immediately
  • Updated std.parseYaml to return null for empty/blank input instead of empty object
  • Improved std.flatMap error messages and added new test cases for type checking

Reviewed changes

Copilot reviewed 37 out of 38 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
sync_test_suites.sh New bash script to sync test suites from upstream repositories, excluding lint/formatter files
refresh_golden_outputs.sh New script to regenerate golden files using sjsonnet
BaseFileTests.scala (jvm-native) Added failure collection mechanism and summary reporting for better test diagnostics
BaseFileTests.scala (js) Added failure collection mechanism and summary reporting for JS platform
FileTests.scala (jvm-native) Added deep_array_nesting test to skip list and calls to printSummaryAndAssert
FileTests.scala (js) Added calls to printSummaryAndAssert for consistent test reporting
StdFlatMapTests.scala Updated test to match improved error message for flatMap on strings
ManifestModule.scala Changed parseYaml to use isBlank instead of isEmpty for consistency with upstream
ArrayModule.scala Updated flatMap error messages to be more descriptive
Platform.scala (all platforms) Changed yamlToJson to return ujson.Null instead of ujson.Obj() for empty input
stdlib.jsonnet Added regression test for parseYaml with empty input
Various test files Added new test cases and golden files for flatMap type checking, digit separators, and other features

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@stephenamar-db stephenamar-db merged commit bc67e65 into databricks:master Feb 27, 2026
11 of 12 checks passed
@He-Pin He-Pin deleted the tests branch February 27, 2026 22:58
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.

3 participants