PJS001 Correct conversion based units - v2

001 | @implementer-agreement
002 | @PJS
003 | @version2
004 | Feature: PJS001 - Correct conversion based units
005 |
006 |   The rule verifies that conversion-based units used per Concept Template 4.1.9.9
007 |   (https://ifc43-docs.standards.buildingsmart.org/IFC/RELEASE/IFC4x3/HTML/concepts/Project_Context/Project_Units/content.html)
008 |   have names and corresponding conversion factors per the table of recommended values.
009 |   This table is not considered to be a normative reference.
010 |   Therefore all schema versions are checked against the latest table from IFC 4X3:
011 |   https://ifc43-docs.standards.buildingsmart.org/IFC/RELEASE/IFC4x3/HTML/lexical/IfcConversionBasedUnit.htm.
012 |
013 |   Background: Selection of conversion-based units in default unit assignment
014 |     Given an .IfcProject.
015 |     Given its attribute .UnitsInContext.
016 |     Given its attribute .Units.
017 |     Given [its entity type] ^is^ 'IfcConversionBasedUnit'
018 |
019 |   Scenario: Validating correct names for area, length, and volume units
020 |     Given .UnitType. ^is^ 'AREAUNIT' or 'LENGTHUNIT' or 'VOLUMEUNIT' or 'PLANEANGLEUNIT'
021 |     Then its attribute .Name. must be defined [according to the table] 'valid_ConversionBasedUnits'
022 |
023 |   Scenario: Validating correct conversion factors
024 |     Then its attribute .ConversionFactor. must be defined [according to the table] 'valid_ConversionBasedUnits'
025 |
026 |   Scenario: Validating that the conversion is based on SI units
027 |     Given its attribute .ConversionFactor.
028 |     Given its attribute .UnitComponent.
029 |     Then [its entity type] ^is^ 'IfcSIUnit'
030 |
031 |   Scenario Outline: Validating that the conversion is based on the correct SI unit
032 |     Given .UnitType. ^is^ '<UnitType>'
033 |     Given its attribute .ConversionFactor.
034 |     Given its attribute .UnitComponent.
035 |     Then the value of attribute .Name. must be '<CorrespondingSIUnit>'
036 |
037 |      Examples:
038 |       | UnitType          | CorrespondingSIUnit   |
039 |       | AREAUNIT          | SQUARE_METRE          |
040 |       | LENGTHUNIT        | METRE                 |
041 |       | VOLUMEUNIT        | CUBIC_METRE           |
042 |       | PLANEANGLEUNIT    | RADIAN                |

Version history

Version

Tag

Date

Commit

Rule link

v1

v0.8.3

2025-11-20

7c8ba3c5

view

v2

n/a

2025-12-28

e914eef3

n/a