Skip to content

Conversation

@7ttp
Copy link
Contributor

@7ttp 7ttp commented Dec 6, 2025

when running supabase db test from a docker-outside-of-docker environment, test file paths may be absolute host paths while utils.DbTestsDir is relative. filepath.Rel fails when the base path is relative and the target is absolute, producing the error: Rel: can't make /path/to/supabase/tests relative to supabase/tests. this change converts both paths to absolute before computing the relative path, which handles all path combinations correctly.

cc @sweatybridge

closes #4523

when running supabase db test from a docker-outside-of-docker environment,
test file paths may be absolute host paths while utils.DbTestsDir is relative.
filepath.Rel fails when the base path is relative and the target is absolute.

this change converts both paths to absolute before computing the relative path,
which handles all path combinations correctly: relative+relative, absolute+absolute,
and mixed scenarios like docker-outside-of-docker.

closes supabase#3194
@7ttp 7ttp requested a review from a team as a code owner December 6, 2025 13:00
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.

Unable to run supabase test db when using docker-outside-of-docker

1 participant