df-derive 0.3.0

Derive fast conversions from Rust structs into Polars DataFrames.
Documentation
#[test]
fn tests() {
    let t = trybuild::TestCases::new();

    // These files should compile successfully.
    t.pass("tests/pass/01-simple-struct.rs");
    t.pass("tests/pass/02-all-supported-types.rs");
    t.pass("tests/pass/03-options-and-nulls.rs");
    t.pass("tests/pass/04-empty-struct.rs");
    t.pass("tests/pass/05-nested-structs.rs");
    t.pass("tests/pass/06-vec-consistency-test.rs");
    t.pass("tests/pass/07-edge-cases-test.rs");
    t.pass("tests/pass/08-vec-custom-struct-test.rs");
    t.pass("tests/pass/09-vec-custom-struct-edge-cases.rs");
    t.pass("tests/pass/10-vec-custom-struct-validation.rs");
    t.pass("tests/pass/11-large-scale-stress.rs");
    t.pass("tests/pass/12-self-referential.rs");
    t.pass("tests/pass/13-field-as-string-attribute.rs");
    t.pass("tests/pass/14-decimal-datetime.rs");
    t.pass("tests/pass/15-as-string-on-struct.rs");
    t.pass("tests/pass/16-tuple-structs.rs");
    t.pass("tests/pass/17-nested-tuple-structs.rs");
    t.pass("tests/pass/18-custom-trait.rs");
    t.pass("tests/pass/19-complex-wrappers.rs");
    t.pass("tests/pass/20-generics.rs");
    t.pass("tests/pass/21-field-as-str-attribute.rs");
    t.pass("tests/pass/22-as-str-on-struct.rs");
    t.pass("tests/pass/23-as-str-redundant-on-string.rs");
    t.pass("tests/pass/24-decimal-and-time-unit-attrs.rs");
    t.pass("tests/pass/25-doubly-optional-nested.rs");
    t.pass("tests/pass/26-generics-no-clone.rs");
    t.pass("tests/pass/27-decimal-i128-direct.rs");
    t.pass("tests/pass/29-decimal128-encode-trait.rs");
    t.pass("tests/pass/34-doubly-optional-primitive.rs");
    t.pass("tests/pass/35-isize-usize.rs");
    t.pass("tests/pass/37-naive-and-duration.rs");
    t.pass("tests/pass/40-reversed-trait-overrides.rs");
    t.pass("tests/pass/42-naive-datetime.rs");
    t.pass("tests/pass/43-i128-u128.rs");
    t.pass("tests/pass/44-cow-unsized.rs");
    t.pass("tests/pass/46-datetime-timezones.rs");
    t.pass("tests/pass/47-option-access-chain-no-clone.rs");
    t.pass("tests/pass/48-runtime-override-combinations.rs");

    // These files should fail to compile.
    t.compile_fail("tests/fail/96-fail-derive-on-union.rs");
    t.compile_fail("tests/fail/97-fail-derive-on-enum.rs");
    t.compile_fail("tests/fail/98-fail-unsupported-type.rs");
    t.compile_fail("tests/fail/99-fail-as-str-and-as-string-conflict.rs");
    t.compile_fail("tests/fail/100-fail-unknown-field-attribute.rs");
    t.compile_fail("tests/fail/101-fail-decimal-on-non-decimal.rs");
    t.compile_fail("tests/fail/102-fail-time-unit-on-non-datetime.rs");
    t.compile_fail("tests/fail/103-fail-time-unit-invalid-value.rs");
    t.compile_fail("tests/fail/104-fail-decimal-precision-out-of-range.rs");
    t.compile_fail("tests/fail/105-fail-decimal-with-as-string.rs");
    t.compile_fail("tests/fail/106-fail-as-str-on-non-string-base.rs");
    t.compile_fail("tests/fail/107-fail-as-binary-bare-u8.rs");
    t.compile_fail("tests/fail/108-fail-as-binary-option-u8.rs");
    t.compile_fail("tests/fail/109-fail-as-binary-vec-option-u8.rs");
    t.compile_fail("tests/fail/110-fail-as-binary-non-u8-leaf.rs");
    t.compile_fail("tests/fail/111-fail-as-binary-on-string.rs");
    t.compile_fail("tests/fail/112-fail-as-binary-with-as-string.rs");
    t.compile_fail("tests/fail/113-fail-as-binary-with-as-str.rs");
    t.compile_fail("tests/fail/114-fail-as-binary-with-decimal.rs");
    t.compile_fail("tests/fail/115-fail-as-binary-with-time-unit.rs");
    t.compile_fail("tests/fail/116-fail-bare-duration-ambiguous.rs");
    t.compile_fail("tests/fail/117-fail-time-unit-on-naive-date.rs");
    t.compile_fail("tests/fail/118-fail-time-unit-on-naive-time.rs");
    t.compile_fail("tests/fail/119-fail-cow-bytes-without-as-binary.rs");
    t.compile_fail("tests/fail/120-fail-cow-non-u8-slice.rs");
    t.compile_fail("tests/fail/121-fail-unit-tuple-field.rs");
    t.compile_fail("tests/fail/122-fail-as-str-on-tuple.rs");
    t.compile_fail("tests/fail/123-fail-as-string-on-tuple.rs");
    t.compile_fail("tests/fail/124-fail-as-binary-on-tuple.rs");
    t.compile_fail("tests/fail/125-fail-decimal-on-tuple.rs");
    t.compile_fail("tests/fail/126-fail-time-unit-on-tuple.rs");
    t.compile_fail("tests/fail/127-fail-external-time-duration.rs");
    t.compile_fail("tests/fail/128-fail-cow-bytes-in-tuple.rs");
    t.compile_fail("tests/fail/129-fail-borrowed-bytes-without-as-binary.rs");
    t.compile_fail("tests/fail/130-fail-borrowed-non-u8-slice.rs");
    t.compile_fail("tests/fail/131-fail-as-binary-borrowed-non-u8-slice.rs");
    t.compile_fail("tests/fail/132-fail-as-str-concrete-type-without-as-ref.rs");
    t.compile_fail("tests/fail/133-fail-skip-with-conversion-attr.rs");
    t.compile_fail("tests/fail/134-fail-as-string-concrete-type-without-display.rs");
    t.compile_fail("tests/fail/135-fail-wrapped-nested-tuple-parent.rs");
    t.compile_fail("tests/fail/136-fail-wrapped-nested-tuple-element.rs");
    t.compile_fail("tests/fail/137-fail-duplicate-override-attributes.rs");
    t.compile_fail("tests/fail/138-fail-columnar-without-trait.rs");
    t.compile_fail("tests/fail/139-fail-duplicate-container-attributes.rs");
    t.compile_fail("tests/fail/140-fail-unsupported-collections.rs");
    t.compile_fail("tests/fail/141-fail-as-string-on-std-duration.rs");
    t.compile_fail("tests/fail/142-fail-as-string-on-borrowed-bytes.rs");
    t.compile_fail("tests/fail/143-fail-as-string-on-borrowed-slice.rs");
    t.compile_fail("tests/fail/144-fail-vec-wrapped-nested-tuple.rs");
    t.compile_fail("tests/fail/145-fail-duplicate-decimal-keys.rs");
    t.compile_fail("tests/fail/146-fail-direct-self-recursive-field.rs");
    t.compile_fail("tests/fail/147-fail-unsized-smart-pointer-leaves.rs");
    t.compile_fail("tests/fail/148-fail-mutable-references.rs");
    t.compile_fail("tests/fail/149-fail-missing-concrete-eager-bounds.rs");
    t.compile_fail("tests/fail/150-fail-skip-with-as-string.rs");
    t.compile_fail("tests/fail/151-fail-decimal-with-time-unit.rs");
}