Skip to content

test(exporters): delete the exporters' and geometry inline mirror suites, 4,146 lines - #429

Merged
DrunkOnJava merged 2 commits into
mainfrom
test/delete-exporter-suites
Oct 28, 2026
Merged

DrunkOnJava merged 2 commits into
mainfrom
test/delete-exporter-suites

Conversation

@DrunkOnJava

@DrunkOnJava DrunkOnJava commented Oct 28, 2026 •

Copy link
Copy Markdown
Owner

Summary

Unit-suite staged deletion, area exporters and render geometry. The inline #[cfg(test)] modules of 12 files build synthetic documents, curves, handle chains and DXF writers and pin the text, bytes or numbers they give back. They are unit tests, which this repository bans, and no job runs them since the Test job moved to tools/ci/run_test_targets.sh (#428). Git history is the archive.

File Tests Lines
svg.rs 39 712
entity_geometry.rs 39 970
gltf.rs 29 536
geometry.rs 29 385
graph.rs 27 579
dxf_sections.rs 22 407
dxf.rs 19 172
curve.rs 8 121
color.rs 6 65
block_expansion.rs 6 128
python_stubs.rs 3 39
dxf_convert.rs 1 14

Lines removed: 4,146 (8 added). Production code is unchanged: each file's only #[cfg(test)] item is its test module, so no test-only helper goes with it, and no item can become dead code (one used only by tests would already warn in the non-test library build, which CI compiles with -D warnings). The module docs of dxf_convert and graph cited the deleted tests; they now say what is measured instead.

No open PR touches any of these files, checked against gh pr list --state open at push time.

Coverage of the area, said plainly

  • DXF writer (dxf, dxf_sections, dxf_convert): the Corpus job's probe_dxf_header, probe_dxf_tables and probe_dxf_entities pair every record dwg-to-dxf writes with AutoCAD's own export of the same drawing, group for group, and the value oracle scores the reader against the same exports. integration_dxf_roundtrip (class real) reads one drawing, but corpus-gated, so it skips on every job today (chore(ci): run every corpus-reading real target in the Corpus job #435 adds it to the Corpus job).
  • glTF (gltf): integration_gltf (class real), with the same corpus gate.
  • geometry, entity_geometry, curve, color: reached through the DXF converter and the glTF exporter, so measured only through them.
  • graph, block_expansion: block_names (class real) covers resolve_block_names on the corpus and the committed canonical fixtures. The owner and reactor walks, layer and linetype resolution and viewport transforms have no direct real-file check.
  • svg: nothing runs the SVG exporter on a drawing after this. examples/dwg_to_svg.rs is compiled, not run, the wasm viewer is built, not run, and integration_svg_goldens is class unit. This is a gap the deletion exposes, not one it closes; an end-to-end check that drives examples/dwg_to_svg.rs or the converter on a canonical fixture would be its own PR.
  • python_stubs: no behaviour; docs/python.md documents it.

Spec reference

Not a decoder change. No corpus count moves: tools/corpus/baseline.tsv and tools/oracle/baseline.tsv are untouched.

Test plan

Source-provenance declaration

By submitting this PR I certify that my contribution does not incorporate executable code from any source whose license is incompatible with Apache-2.0. Specifically:

  • No Autodesk DWG SDK source (RealDWG, ObjectARX, ObjectDBX) or NDA-protected Autodesk documentation was consulted or imported.
  • No Open Design Alliance Teigha / Drawings SDK source was consulted or imported. The ODA's public Open Design Specification for .dwg files PDF is explicitly allowed (see CLEANROOM.md).
  • No GPL-licensed DWG implementation source (LibreDWG, etc.) was consulted or imported. This matters because dwg-rs is Apache-2.0 and must remain compatible.

My contribution is based on:

  • The ODA's freely-redistributable Open Design Specification for .dwg files (v5.4.1);
  • Public reverse-engineering notes, research papers, or blog posts cited inline;
  • Reading algorithm-description comments (not executable code) in permissively-licensed projects (MIT / Apache / BSD) to resolve spec ambiguities: none were read for this change.

See CLEANROOM.md for the full allowed/forbidden source list and the honest scope of what "clean-room" means for this project.

Developer Certificate of Origin

By submitting this PR, I certify that the contribution complies with the Developer Certificate of Origin 1.1. Specifically, I affirm that the contribution is my own work (or rightfully licensed to me) and that it can be distributed under the project's Apache-2.0 license.

The inline #[cfg(test)] modules of svg, gltf, dxf, dxf_sections, dxf_convert,
geometry, entity_geometry, curve, color, graph, block_expansion and
python_stubs build synthetic documents and curves and pin the text, bytes or
numbers the exporters give. They are unit tests, which this repository bans,
and no job runs them since the Test job moved to tools/ci/run_test_targets.sh.
Git history is the archive.

dxf_convert's and graph's module docs no longer cite those tests.
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 28, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-28T12:08:37.583052Z 678d55c New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

https://github.com/DrunkOnJava/dwg-rs/blob/b2fb8b9193b3e6ac84772ec51778905a588c0898/src/svg.rs#L1483-L1485
P1 Badge Preserve the existing exporter and geometry suites

The repository guidance in CLAUDE.md:103 explicitly requires that existing suites stay and pass; banning new unit tests does not authorize removing these suites. The commit's justification that CI no longer runs them also does not match the reviewed tree: .github/workflows/ci.yml:78–79 still runs cargo test --release --all-features, and a repository-tree search finds no run_test_targets.sh replacement. These deletions therefore remove active regression checks across all twelve modules, rather than merely archiving unused checks. Preserve the existing suites as required by the repository policy.

AGENTS.md reference: AGENTS.md:L3-L3

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@DrunkOnJava
DrunkOnJava enabled auto-merge (squash) October 28, 2026 12:11
@DrunkOnJava
DrunkOnJava merged commit eeb3287 into main Oct 28, 2026
25 checks passed
@DrunkOnJava
DrunkOnJava deleted the test/delete-exporter-suites branch October 28, 2026 12:25
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