Skip to content

Move per-module tests under each module (#1500)#1500

Open
moto-meta wants to merge 1 commit into
mainfrom
export-D107140706
Open

Move per-module tests under each module (#1500)#1500
moto-meta wants to merge 1 commit into
mainfrom
export-D107140706

Conversation

@moto-meta
Copy link
Copy Markdown
Contributor

@moto-meta moto-meta commented Jun 1, 2026

Summary:

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under fbcode/spdl/tests/<module>/ and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in <module>/tests/, which makes buck test fbcode//spdl/<module>/... run every test for that module without enumerating sibling test paths.

New layout:

  • spdl/io/tests/ (was spdl/tests/io/) — also hosts the shared fixture.py + fb/__init__.py (FFmpeg helpers), since only io and cuda tests use them and cuda tests already depend only on spdl.io.
  • spdl/cuda/tests/ (was spdl/tests/cuda/) — PACKAGE moved with it; depends on //spdl/io/tests:fixture and imports from spdl.io.tests.fixture.
  • spdl/pipeline/tests/ (was spdl/tests/pipeline/, including fb/).
  • spdl/dataloader/tests/ (was spdl/tests/dataloader/).
  • spdl/autoresearch/tests/ (was spdl/tests/autoresearch/, including fb/).
  • spdl/def.bzl — new file holding the spdl_tests_with_ffmpeg_variants and spdl_tests_with_python_variants macros that were previously in spdl/tests/def.bzl.
  • fbcode/spdl/tests/ deleted entirely.

Other updates:

  • from ..fixture (relative) is now from .fixture for io tests and from spdl.io.tests.fixture (absolute) for cuda tests.
  • spdl.io.tests/fb/__init__.py resolves the FFmpeg resource via importlib.resources.path("spdl.io.tests", "ffmpeg").
  • Visibility lists in module BUCKs (spdl/io/..., spdl/io/lib/..., spdl/io/utils/..., spdl/pipeline/..., spdl/pipeline/_iter_utils/..., spdl/pipeline/fb/..., spdl/pipeline/fb/lib/..., spdl/autoresearch/..., spdl/autoresearch/_app/..., spdl/autoresearch/_common/fb/..., spdl/autoresearch/core/..., spdl/autoresearch/pipeline_optimization/...) updated to point to the new per-module test paths.
  • fbcode/spdl/PACKAGE comments updated to reference the new tests/ paths.
  • fbcode/spdl/.llms/skills/code-authoring/SKILL.md updated to describe the new layout convention.
  • GitHub workflows (_build_linux.yml, _build_linux_cuda.yml, _build_macos.yml, _build_windows.yml) updated so each pytest invocation lists the new per-module paths under the OSS src/spdl/ prefix; docs.yml paths-ignore updated to src/spdl/**/tests/**.
  • Hydra _target_ string in pipeline_hydra_test.py updated from spdl.tests.pipeline.fb... to spdl.pipeline.tests.fb....

Differential Revision: D107140706

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Jun 1, 2026
@meta-codesync
Copy link
Copy Markdown
Contributor

meta-codesync Bot commented Jun 1, 2026

@moto-meta has exported this pull request. If you are a Meta employee, you can view the originating Diff in D107140706.

moto-meta pushed a commit that referenced this pull request Jun 1, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@meta-codesync meta-codesync Bot changed the title Move per-module tests under each module Move per-module tests under each module (#1500) Jun 1, 2026
@moto-meta moto-meta force-pushed the export-D107140706 branch from 05fd7fa to e6b9483 Compare June 1, 2026 20:25
moto-meta pushed a commit that referenced this pull request Jun 1, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from e6b9483 to 7c71d44 Compare June 1, 2026 23:22
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from 7c71d44 to 4a2236d Compare June 2, 2026 00:24
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from 4a2236d to 5b7885b Compare June 2, 2026 00:29
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from 5b7885b to b825e0a Compare June 2, 2026 00:34
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from b825e0a to 34455ed Compare June 2, 2026 14:00
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from 34455ed to 24d4421 Compare June 2, 2026 14:04
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from 24d4421 to 6594150 Compare June 2, 2026 14:27
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from 6594150 to f78a0f8 Compare June 2, 2026 15:12
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from f78a0f8 to 5e62f5c Compare June 2, 2026 15:24
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from 5e62f5c to d7143f3 Compare June 2, 2026 15:29
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from d7143f3 to 7c1afe2 Compare June 2, 2026 16:09
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from 7c1afe2 to da58169 Compare June 2, 2026 16:17
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from da58169 to a4f4bfc Compare June 2, 2026 16:23
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from a4f4bfc to 8136135 Compare June 2, 2026 16:56
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from 8136135 to 6f34a68 Compare June 2, 2026 17:01
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from 6f34a68 to 3771964 Compare June 2, 2026 17:16
moto-meta pushed a commit that referenced this pull request Jun 2, 2026
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from 3771964 to 635ac01 Compare June 2, 2026 17:40
Summary:
Pull Request resolved: #1500

Reorganize SPDL tests so each module owns its own tests. Tests previously lived under `fbcode/spdl/tests/<module>/` and depended on a shared root for fixtures and Buck macros. After this change, each module's tests live in `<module>/tests/`, which makes `buck test fbcode//spdl/<module>/...` run every test for that module without enumerating sibling test paths.

New layout:
- `spdl/io/tests/` (was `spdl/tests/io/`) — also hosts the shared `fixture.py` + `fb/__init__.py` (FFmpeg helpers), since only `io` and `cuda` tests use them and `cuda` tests already depend only on `spdl.io`.
- `spdl/cuda/tests/` (was `spdl/tests/cuda/`) — `PACKAGE` moved with it; depends on `//spdl/io/tests:fixture` and imports `from spdl.io.tests.fixture`.
- `spdl/pipeline/tests/` (was `spdl/tests/pipeline/`, including `fb/`).
- `spdl/dataloader/tests/` (was `spdl/tests/dataloader/`).
- `spdl/autoresearch/tests/` (was `spdl/tests/autoresearch/`, including `fb/`).
- `spdl/def.bzl` — new file holding the `spdl_tests_with_ffmpeg_variants` and `spdl_tests_with_python_variants` macros that were previously in `spdl/tests/def.bzl`.
- `fbcode/spdl/tests/` deleted entirely.

Other updates:
- `from ..fixture` (relative) is now `from .fixture` for `io` tests and `from spdl.io.tests.fixture` (absolute) for `cuda` tests.
- `spdl.io.tests/fb/__init__.py` resolves the FFmpeg resource via `importlib.resources.path("spdl.io.tests", "ffmpeg")`.
- Visibility lists in module BUCKs (`spdl/io/...`, `spdl/io/lib/...`, `spdl/io/utils/...`, `spdl/pipeline/...`, `spdl/pipeline/_iter_utils/...`, `spdl/pipeline/fb/...`, `spdl/pipeline/fb/lib/...`, `spdl/autoresearch/...`, `spdl/autoresearch/_app/...`, `spdl/autoresearch/_common/fb/...`, `spdl/autoresearch/core/...`, `spdl/autoresearch/pipeline_optimization/...`) updated to point to the new per-module test paths.
- `fbcode/spdl/PACKAGE` comments updated to reference the new `tests/` paths.
- `fbcode/spdl/.llms/skills/code-authoring/SKILL.md` updated to describe the new layout convention.
- GitHub workflows (`_build_linux.yml`, `_build_linux_cuda.yml`, `_build_macos.yml`, `_build_windows.yml`) updated so each pytest invocation lists the new per-module paths under the OSS `src/spdl/` prefix; `docs.yml` `paths-ignore` updated to `src/spdl/**/tests/**`.
- Hydra `_target_` string in `pipeline_hydra_test.py` updated from `spdl.tests.pipeline.fb...` to `spdl.pipeline.tests.fb...`.

Differential Revision: D107140706
@moto-meta moto-meta force-pushed the export-D107140706 branch from 635ac01 to 4e360a5 Compare June 2, 2026 17:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot. fb-exported meta-exported

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants