Include unit test for classes with dynamic properties #12

Closed
opened 2025-10-11 10:08:20 +00:00 by UserCurt · 5 comments
UserCurt commented 2025-10-11 10:08:20 +00:00 (Migrated from codeberg.org)

The large majority of unit tests are done with structures, with some unit tests working with tables and classes. Classes with dynamic properties in particular has not been tested at all. This issue is to add extensive testing with classes implementing dynamic properties to the suite of existing unit tests.

The large majority of unit tests are done with structures, with some unit tests working with tables and classes. [Classes with dynamic properties](https://www.mathworks.com/help/matlab/matlab_oop/dynamic-properties-adding-properties-to-an-instance.html) in particular has not been tested at all. This issue is to add extensive testing with classes implementing dynamic properties to the suite of existing unit tests.
UserCurt commented 2025-10-11 10:09:48 +00:00 (Migrated from codeberg.org)

This issue is labeled as "bug" not because it is strictly a bug but implementation could bring bugs to light.

This issue is labeled as "bug" not because it is strictly a bug but implementation could bring bugs to light.
UserCurt commented 2026-06-25 01:02:33 +00:00 (Migrated from codeberg.org)

This has been partially addressed in commits: cf2cf42, 1334641. A fixture was added that uses dynamicprops, and some non-extensive coverage was set up for creating a dynamic property with set, removing a dynamic property with remove, and discovering dynamic properties with dot operations.

There still needs to be tests for: get, nested dynamic properties, arrays of dynamicprops objects, wildcard traversal through dynamic properties, missing-policy combinations specific to dynamicprops.

This has been partially addressed in commits: `cf2cf42`, `1334641`. A fixture was added that uses `dynamicprops`, and some non-extensive coverage was set up for creating a dynamic property with `set`, removing a dynamic property with `remove`, and discovering dynamic properties with dot operations. There still needs to be tests for: `get`, nested dynamic properties, arrays of `dynamicprops` objects, wildcard traversal through dynamic properties, missing-policy combinations specific to `dynamicprops`.
UserCurt commented 2026-07-21 01:10:45 +00:00 (Migrated from codeberg.org)

Added unit test suite for dynamic properties in 33011ac. Nonscalar instance dynamic-property access remains intentionally excluded because MATLAB does not support array-wide access.

The issue remains open for branch arrays, policy combinations, heterogeneous wildcard holes, and hidden or deleted properties.

Added unit test suite for dynamic properties in `33011ac`. Nonscalar instance dynamic-property access remains intentionally excluded because MATLAB does not support array-wide access. The issue remains open for branch arrays, policy combinations, heterogeneous wildcard holes, and hidden or deleted properties.
UserCurt commented 2026-07-21 02:42:19 +00:00 (Migrated from codeberg.org)

Continued to add unit tests in fb33148, this time for hidden public dynamic properties and deleted properties.

The remaining work is branch-local dynamic properties: homogeneous and heterogeneous child sets, wildcard coordinate holes, and MissingPolicy and NonmissingRequirement combinations.

Continued to add unit tests in `fb33148`, this time for hidden public dynamic properties and deleted properties. The remaining work is branch-local dynamic properties: homogeneous and heterogeneous child sets, wildcard coordinate holes, and `MissingPolicy` and `NonmissingRequirement` combinations.
UserCurt commented 2026-07-22 00:29:18 +00:00 (Migrated from codeberg.org)

Finished in 3f55368, which covers dynamic properties across object-array branches.

Direct array-wide access to instance dynamic properties remains intentionally unsupported because MATLAB does not support it.

Finished in `3f55368`, which covers dynamic properties across object-array branches. Direct array-wide access to instance dynamic properties remains intentionally unsupported because MATLAB does not support it.
Sign in to join this conversation.
No description provided.