lean4-htt/tests/pkg/mod_clash/test.sh
Mac Malone 687698e79d
test: module clash across packages (#11246)
This PR adds a test that covers importing modules defined in multiple
packages.

Currently, will resolve the module to its first occurrence in the its
search order. However, this will soon change, so this test is designed
to analyze that behavior.
2025-11-19 02:23:34 +00:00

13 lines
401 B
Bash
Executable file

#!/usr/bin/env bash
source ../../lake/tests/common.sh
# This test covers importing modules which are defined in multiple packages.
./clean.sh
test_run resolve-deps
# Test that importing a module with multiple equivalent candidates works
test_run build Test.ImportSame
# Test that importing a module with multiple distinct candidates fails
test_err 'Unknown identifier `foo`' build Test.ImportDiff