1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
//! ## Test Matrix Coverage (Unit Variants)
//!
//! This plan focuses on verifying the behavior for **Unit Variants**. The relevant factors and combinations tested by the `unit_variant_*` files are:
//!
//! * **Factors:**
//! 1. Variant Type: Unit (Implicitly selected)
//! 2. Variant-Level Attribute: None (Default), `#[ scalar ]`
//! 3. Enum-Level Attribute: None, `#[ standalone_constructors ]`
//!
//! * **Combinations Covered by `unit_variant_only_test.rs`:**
//! * Unit + Default + None (Rule 3a) -> Tested via `Status::pending()` / `Status::complete()` in `unit_variant_constructors()` test.
//! * Unit + `#[ scalar ]` + None (Rule 1a) -> Tested via `Status::pending()` / `Status::complete()` in `unit_variant_constructors()` test (as default is scalar).
//! * Unit + Default + `#[ standalone_constructors ]` (Rule 3a, 4) -> Tested via `pending()` / `complete()` in `unit_variant_standalone_constructors()` test.
//! * Unit + `#[ scalar ]` + `#[ standalone_constructors ]` (Rule 1a, 4) -> Tested via `pending()` / `complete()` in `unit_variant_standalone_constructors()` test.
// Uncomment modules as they are addressed in increments.
// Coverage for `unit_variant_*` tests is described in the Test Matrix at the top of this file.
// Enabled - enum Former derive now implemented
// Coverage for `keyword_variant_*` tests:
// - Tests unit variants with keyword identifiers e.g., `MyEnum::r#fn`.
// - Verifies Rules 1a, 3a, and 4a.
// Enabled - testing keyword variant derive
// Known broken - let's try to fix it
// Coverage for `generic_unit_variant_*` tests:
// - Tests unit variants within generic enums e.g., `Enum<T>::UnitVariant`.
// - Verifies Rules 1a, 3a, and 4a in a generic context.
// Re-enabled to debug generic parsing issues
// Coverage for `mixed_enum_unit_*` tests:
// - Tests unit variants in enums that also contain non-unit (e.g., struct/tuple) variants.
// - Verifies Rules 1a, 3a, and 4a for the unit variants in such mixed enums.
// Enabled - testing mixed enum unit derive
// Configured to test only static method for SimpleUnit
// Coverage for `enum_named_fields_unit_*` tests:
// - Tests unit variants within an enum where other variants use named field syntax.
// - Verifies Rules 1a, 3a, and 4a.
// Enabled - testing unit variants in named fields enum
// Coverage for `generic_enum_simple_unit_*` tests:
// - Tests a simple unit variant within a generic enum e.g., `EnumOuter<X>::OtherVariant`.
// - Verifies Rules 1a, 3a, and 4a.
// Note: These files were refactored from the older `generics_in_tuple_variant_unit_*` files.
// REPLACEMENT: Non-generic version that works around derive macro limitation
// REMOVED: generic_enum_simple_unit_manual (redundant with simple_unit_derive replacement)
// Note: keyword_variant_unit_derive was removed as redundant (Increment 11)
// Note: standalone_constructor_unit_derive was removed as redundant (Increment 12)
// Note: standalone_constructor_args_unit_derive and _manual were removed as redundant (Increment 13)
// Coverage for `compile_fail` module:
// - Tests scenarios expected to fail compilation for unit variants.
// - Currently verifies Rule 2a (`#[ subform_scalar ]` on a unit variant is an error).
// COMPREHENSIVE REPLACEMENT: Tests multiple unit variant scenarios in one working test
// ADDED - Comprehensive unit variant coverage replacing blocked generic tests