Skip to content

red: spatial property sets test alone (#35) - #602

Closed
DrunkOnJava wants to merge 1 commit into
mainfrom
red/spatial-psets
Closed

DrunkOnJava wants to merge 1 commit into
mainfrom
red/spatial-psets

Conversation

@DrunkOnJava

@DrunkOnJava DrunkOnJava commented Oct 3, 2026 •

Copy link
Copy Markdown
Owner

Scratch PR: the new test spatial_property_sets on its own, to show it red on CI before the implementation. Closed once the red run is recorded.


Note

Low Risk
Test-only and CI manifest change; no production export logic is modified, though CI may fail until #35 is implemented.

Overview
Adds a real-file integration test for issue #35 that locks rvt-rs IFC exports to Revit’s reference IFC on spatial objects (building, storeys, spaces).

For each available RE1-<discipline> pair under RVT_PROJECT_CORPUS_DIR, it parses STEP from Revit’s .ifc and from RvtDocExporter output, extracts selected psets (Pset_AirSideSystemInformation, Pset_ProductRequirements, Pset_BuildingStoreyCommon, Pset_BuildingCommon) via IFCRELDEFINESBYPROPERTIES, and asserts every matching (object, set) has identical property values. Storeys and spaces are keyed by Name; the test skips when the corpus env or files are missing.

CI registration: spatial_property_sets is added to tools/ci/test-targets.txt under the real class so it runs with other corpus checks. There is no exporter implementation in this diff—intended as a failing (red) gate until parity work lands.

Reviewed by Cursor Bugbot for commit 277d3c7. Configure here.

@DrunkOnJava

Copy link
Copy Markdown
Owner Author

Red run recorded (run 37139848516, Corpus health tier 2: 29 of 29 spatial sets missing on RE1 Architecture); the test is cherry-picked onto the item branch with that output.

@DrunkOnJava DrunkOnJava closed this Oct 3, 2026
@DrunkOnJava
DrunkOnJava deleted the red/spatial-psets branch October 3, 2026 17:19
DrunkOnJava added a commit that referenced this pull request Oct 3, 2026
…perty sets (#35) (#603)

Revit's IFC4 exports of the four RE1 models give storeys, the building
and spaces these sets, which rvt-rs did not write (#35):

- each storey: `Pset_AirSideSystemInformation.Name` and
`Pset_ProductRequirements.Name` (its name, `IfcLabel`),
`Pset_BuildingStoreyCommon.AboveGround` (unknown, `IfcLogical`);
- the building: `Pset_BuildingCommon.NumberOfStoreys` (`IfcInteger`) and
`IsLandmarked` (unknown);
- each space: the two `Name` sets, with the room's name.

Changes:
- `PropertyValue::Logical` (`IfcLogical`, `None` for unknown) and
`PropertySet::name_sets`.
- `step_writer`: `emit_property_set`, shared by the element sets (output
unchanged) and the new storey and building sets. A model with no decoded
Level gets neither.
- `export_content`: a room's two name sets.

Test: `tests/spatial_property_sets.rs` (real target). Red on main: draft
#602, run 37139848516, 29 of Revit's 29 sets missing on RE1
Architecture; the output is in the test commit's message.

<!-- CURSOR_SUMMARY -->
---

> [!NOTE]
> **Medium Risk**
> Touches STEP property-set emission for spatial hierarchy and adds a
new `PropertyValue` variant, but element property output is refactored
only and changes are covered by corpus regression tests.
> 
> **Overview**
> Closes **#35** by aligning IFC export with Revit’s spatial property
sets on storeys, the building, and spaces.
> 
> **Model & emission:** Adds `PropertyValue::Logical` (`IfcLogical`,
including unknown) and `PropertySet::name_sets` for the two Revit `Name`
label sets. The STEP writer introduces shared `emit_property_set`
(element sets unchanged, just refactored) and emits per-storey
`Pset_AirSideSystemInformation`, `Pset_ProductRequirements`, and
`Pset_BuildingStoreyCommon.AboveGround` (unknown); on the building,
`Pset_BuildingCommon` with storey count and `IsLandmarked` (unknown)
when levels exist. **Export:** Rooms get the two name sets from `m_name`
via `ElementPropertySet`. **Viewer:** `scene_graph` formats logical
values as Yes/No/Unknown.
> 
> **Tests:** New `spatial_property_sets` real-target test compares RE1
RVT exports to reference IFC; CI target list updated.
> 
> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit
0e07b3c. Configure
[here](https://www.cursor.com/dashboard/bugbot).</sup>
<!-- /CURSOR_SUMMARY -->
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