From 004f8f4e38e1079589b4472025dbeb6e2e7b5d02 Mon Sep 17 00:00:00 2001 From: Samuel Guerra Date: Thu, 4 Apr 2024 23:30:34 -0300 Subject: [PATCH] Rename "build tests" to "macro tests". More CI parallelism. --- .github/workflows/ci.yml | 68 +++++++++++++++++-- .github/workflows/release-1-test-tag.yml | 6 +- .vscode/tasks.json | 18 ----- Cargo.toml | 2 +- tests/README.md | 6 +- tests/build/main.rs | 9 --- tests/{build => macro-tests}/Cargo.toml | 2 +- .../cases/property/args_count_no_input.rs | 0 .../cases/property/args_count_no_input.stderr | 0 .../cases/property/args_count_none.rs | 0 .../cases/property/args_count_none.stderr | 0 .../cases/property/cannot_declare_lifetime.rs | 0 .../property/cannot_declare_lifetime.stderr | 0 .../child_type_constraints_ui_node.rs | 0 .../child_type_constraints_ui_node.stderr | 0 .../property/child_type_is_not_ui_node.rs | 0 .../property/child_type_is_not_ui_node.stderr | 0 .../cases/property/defaults.rs | 0 .../cases/property/defaults.stderr | 0 .../cases/property/incorrect_attr_args.rs | 0 .../cases/property/incorrect_attr_args.stderr | 0 .../property/invalid_function_qualifiers.rs | 0 .../invalid_function_qualifiers.stderr | 0 .../cases/property/invalid_input_pattern.rs | 0 .../property/invalid_input_pattern.stderr | 0 .../cases/property/invalid_priority.rs | 0 .../cases/property/invalid_priority.stderr | 0 .../property/method_cannot_be_property.rs | 0 .../property/method_cannot_be_property.stderr | 0 .../cases/property/prefix_get_default.rs | 0 .../cases/property/prefix_get_default.stderr | 0 .../cases/property/prefix_has_default.rs | 0 .../cases/property/prefix_has_default.stderr | 0 .../cases/property/prefix_is_default.rs | 0 .../cases/property/prefix_is_default.stderr | 0 .../cases/property/property_attr_not_fn.rs | 0 .../property/property_attr_not_fn.stderr | 0 .../property/return_type_is_not_ui_node.rs | 0 .../return_type_is_not_ui_node.stderr | 0 .../cases/ui_node/attr_in_item_not_impl.rs | 0 .../ui_node/attr_in_item_not_impl.stderr | 0 .../delegate_expr_error_incorrect_mut.rs | 0 .../delegate_expr_error_incorrect_mut.stderr | 0 .../delegate_expr_error_incorrect_type.rs | 0 .../delegate_expr_error_incorrect_type.stderr | 0 ...elegate_expr_error_incorrect_type_child.rs | 0 ...ate_expr_error_incorrect_type_child.stderr | 0 .../ui_node/delegate_expr_error_no_field.rs | 0 .../delegate_expr_error_no_field.stderr | 0 .../delegate_expr_no_children_field.rs | 0 .../delegate_expr_no_children_field.stderr | 0 .../delegate_list_expr_error_incorrect_mut.rs | 0 ...egate_list_expr_error_incorrect_mut.stderr | 0 ...delegate_list_expr_error_incorrect_type.rs | 0 ...gate_list_expr_error_incorrect_type.stderr | 0 ...list_expr_error_incorrect_type_children.rs | 0 ..._expr_error_incorrect_type_children.stderr | 0 .../cases/ui_node/incorrect_assign_token.rs | 0 .../ui_node/incorrect_assign_token.stderr | 0 .../cases/ui_node/invalid_args.rs | 0 .../cases/ui_node/invalid_args.stderr | 0 .../ui_node/invalid_delegate_pair_name.rs | 0 .../ui_node/invalid_delegate_pair_name.stderr | 0 .../cases/ui_node/missing_delegate_expr.rs | 0 .../ui_node/missing_delegate_expr.stderr | 0 .../missing_matching_delegate_child.rs | 0 .../missing_matching_delegate_child.stderr | 0 .../widget/cannot_instantiate_widget_mixin.rs | 0 .../cannot_instantiate_widget_mixin.stderr | 0 .../cases/widget/module_path_malformed2.rs | 0 .../widget/module_path_malformed2.stderr | 0 .../cases/widget/module_path_malformed3.rs | 0 .../widget/module_path_malformed3.stderr | 0 .../cases/widget/module_path_missing.rs | 0 .../cases/widget/module_path_missing.stderr | 0 .../cases/widget/module_path_missing_crate.rs | 0 .../widget/module_path_missing_crate.stderr | 0 .../widget/module_path_missing_dollar_sign.rs | 0 .../module_path_missing_dollar_sign.stderr | 0 .../cases/widget/name_conflict1.rs | 0 .../cases/widget/name_conflict1.stderr | 0 .../cases/widget/name_conflict2.rs | 0 .../cases/widget/name_conflict2.stderr | 0 .../cases/widget/parent_not_widget.rs | 0 .../cases/widget/parent_not_widget.stderr | 0 .../cases/widget/type_path_is_invalid1.rs | 0 .../cases/widget/type_path_is_invalid1.stderr | 0 .../cases/widget/type_path_malformed1.rs | 0 .../cases/widget/type_path_malformed1.stderr | 0 .../cases/widget/unknown_inherit.rs | 0 .../cases/widget/unknown_inherit.stderr | 0 .../cases/widget/util/a_mod.rs | 0 .../cases/widget_new/cannot_unset_in_when.rs | 0 .../widget_new/cannot_unset_in_when.stderr | 0 .../cases/widget_new/error_first_token.rs | 0 .../cases/widget_new/error_first_token.stderr | 0 .../widget_new/error_in_property_expr.rs | 0 .../widget_new/error_in_property_expr.stderr | 0 .../cases/widget_new/error_in_when_expr1.rs | 0 .../widget_new/error_in_when_expr1.stderr | 0 .../cases/widget_new/error_in_when_expr2.rs | 0 .../widget_new/error_in_when_expr2.stderr | 0 .../cases/widget_new/error_in_when_expr3.rs | 0 .../widget_new/error_in_when_expr3.stderr | 0 .../cases/widget_new/incorrect_arg_type1.rs | 0 .../widget_new/incorrect_arg_type1.stderr | 0 .../cases/widget_new/incorrect_arg_type2.rs | 0 .../widget_new/incorrect_arg_type2.stderr | 0 .../cases/widget_new/incorrect_arg_type3.rs | 0 .../widget_new/incorrect_arg_type3.stderr | 0 .../cases/widget_new/incorrect_arg_type4.rs | 0 .../widget_new/incorrect_arg_type4.stderr | 0 .../cases/widget_new/incorrect_arg_type5.rs | 0 .../widget_new/incorrect_arg_type5.stderr | 0 .../cases/widget_new/incorrect_arg_type6.rs | 0 .../widget_new/incorrect_arg_type6.stderr | 0 .../widget_new/incorrect_when_expr_type1.rs | 0 .../incorrect_when_expr_type1.stderr | 0 .../cases/widget_new/invalid_special.rs | 0 .../cases/widget_new/invalid_special.stderr | 0 .../cases/widget_new/malformed_fields1.rs | 0 .../cases/widget_new/malformed_fields1.stderr | 0 .../cases/widget_new/malformed_fields2.rs | 0 .../cases/widget_new/malformed_fields2.stderr | 0 .../malformed_property_attribute.rs | 0 .../malformed_property_attribute.stderr | 0 .../widget_new/malformed_property_path1.rs | 0 .../malformed_property_path1.stderr | 0 .../widget_new/malformed_property_path2.rs | 0 .../malformed_property_path2.stderr | 0 .../widget_new/malformed_property_path3.rs | 0 .../malformed_property_path3.stderr | 0 .../widget_new/malformed_property_path4.rs | 0 .../malformed_property_path4.stderr | 0 .../cases/widget_new/missing_arg1.rs | 0 .../cases/widget_new/missing_arg1.stderr | 0 .../widget_new/missing_field_all_multi.rs | 0 .../widget_new/missing_field_all_multi.stderr | 0 .../widget_new/missing_field_all_single.rs | 0 .../missing_field_all_single.stderr | 0 .../cases/widget_new/missing_field_multi.rs | 0 .../widget_new/missing_field_multi.stderr | 0 .../cases/widget_new/missing_semi1.rs | 0 .../cases/widget_new/missing_semi1.stderr | 0 .../cases/widget_new/missing_semi2.rs | 0 .../cases/widget_new/missing_semi2.stderr | 0 .../widget_new/missing_semi_before_when1.rs | 0 .../missing_semi_before_when1.stderr | 0 .../cases/widget_new/missing_semi_in_when1.rs | 0 .../widget_new/missing_semi_in_when1.stderr | 0 .../cases/widget_new/missing_semi_in_when2.rs | 0 .../widget_new/missing_semi_in_when2.stderr | 0 .../cases/widget_new/missing_value1.rs | 0 .../cases/widget_new/missing_value1.stderr | 0 .../cases/widget_new/missing_value2.rs | 0 .../cases/widget_new/missing_value2.stderr | 0 .../cases/widget_new/missing_value3.rs | 0 .../cases/widget_new/missing_value3.stderr | 0 .../cases/widget_new/missing_value4.rs | 0 .../cases/widget_new/missing_value4.stderr | 0 .../cases/widget_new/missing_value5.rs | 0 .../cases/widget_new/missing_value5.stderr | 0 .../cases/widget_new/missing_value6.rs | 0 .../cases/widget_new/missing_value6.stderr | 0 .../widget_new/missing_value_before_when1.rs | 0 .../missing_value_before_when1.stderr | 0 .../cases/widget_new/not_allowed_in_when1.rs | 0 .../widget_new/not_allowed_in_when1.stderr | 0 .../cases/widget_new/not_allowed_in_when2.rs | 0 .../widget_new/not_allowed_in_when2.stderr | 0 .../cases/widget_new/property_generic1.rs | 0 .../cases/widget_new/property_generic1.stderr | 0 .../cases/widget_new/property_generic2.rs | 0 .../cases/widget_new/property_generic2.stderr | 0 .../cases/widget_new/unknown_field.rs | 0 .../cases/widget_new/unknown_field.stderr | 0 .../unknown_member_in_when_expr1.rs | 0 .../unknown_member_in_when_expr1.stderr | 0 .../unknown_member_in_when_expr2.rs | 0 .../unknown_member_in_when_expr2.stderr | 0 .../cases/widget_new/unknown_property1.rs | 0 .../cases/widget_new/unknown_property1.stderr | 0 .../cases/widget_new/unknown_property2.rs | 0 .../cases/widget_new/unknown_property2.stderr | 0 .../cases/widget_new/unknown_special_value.rs | 0 .../widget_new/unknown_special_value.stderr | 0 .../unknown_special_value_in_when.rs | 0 .../unknown_special_value_in_when.stderr | 0 .../cases/widget_new/when_missing_block.rs | 0 .../widget_new/when_missing_block.stderr | 0 .../cases/widget_new/when_missing_expr1.rs | 0 .../widget_new/when_missing_expr1.stderr | 0 tests/macro-tests/main.rs | 9 +++ tests/{build => macro-tests}/run.rs | 4 +- tools/do-tasks/src/main.rs | 46 ++++++------- tools/do-tasks/src/util.rs | 6 +- zng-time/src/lib.rs | 4 +- 197 files changed, 114 insertions(+), 66 deletions(-) delete mode 100644 tests/build/main.rs rename tests/{build => macro-tests}/Cargo.toml (90%) rename tests/{build => macro-tests}/cases/property/args_count_no_input.rs (100%) rename tests/{build => macro-tests}/cases/property/args_count_no_input.stderr (100%) rename tests/{build => macro-tests}/cases/property/args_count_none.rs (100%) rename tests/{build => macro-tests}/cases/property/args_count_none.stderr (100%) rename tests/{build => macro-tests}/cases/property/cannot_declare_lifetime.rs (100%) rename tests/{build => macro-tests}/cases/property/cannot_declare_lifetime.stderr (100%) rename tests/{build => macro-tests}/cases/property/child_type_constraints_ui_node.rs (100%) rename tests/{build => macro-tests}/cases/property/child_type_constraints_ui_node.stderr (100%) rename tests/{build => macro-tests}/cases/property/child_type_is_not_ui_node.rs (100%) rename tests/{build => macro-tests}/cases/property/child_type_is_not_ui_node.stderr (100%) rename tests/{build => macro-tests}/cases/property/defaults.rs (100%) rename tests/{build => macro-tests}/cases/property/defaults.stderr (100%) rename tests/{build => macro-tests}/cases/property/incorrect_attr_args.rs (100%) rename tests/{build => macro-tests}/cases/property/incorrect_attr_args.stderr (100%) rename tests/{build => macro-tests}/cases/property/invalid_function_qualifiers.rs (100%) rename tests/{build => macro-tests}/cases/property/invalid_function_qualifiers.stderr (100%) rename tests/{build => macro-tests}/cases/property/invalid_input_pattern.rs (100%) rename tests/{build => macro-tests}/cases/property/invalid_input_pattern.stderr (100%) rename tests/{build => macro-tests}/cases/property/invalid_priority.rs (100%) rename tests/{build => macro-tests}/cases/property/invalid_priority.stderr (100%) rename tests/{build => macro-tests}/cases/property/method_cannot_be_property.rs (100%) rename tests/{build => macro-tests}/cases/property/method_cannot_be_property.stderr (100%) rename tests/{build => macro-tests}/cases/property/prefix_get_default.rs (100%) rename tests/{build => macro-tests}/cases/property/prefix_get_default.stderr (100%) rename tests/{build => macro-tests}/cases/property/prefix_has_default.rs (100%) rename tests/{build => macro-tests}/cases/property/prefix_has_default.stderr (100%) rename tests/{build => macro-tests}/cases/property/prefix_is_default.rs (100%) rename tests/{build => macro-tests}/cases/property/prefix_is_default.stderr (100%) rename tests/{build => macro-tests}/cases/property/property_attr_not_fn.rs (100%) rename tests/{build => macro-tests}/cases/property/property_attr_not_fn.stderr (100%) rename tests/{build => macro-tests}/cases/property/return_type_is_not_ui_node.rs (100%) rename tests/{build => macro-tests}/cases/property/return_type_is_not_ui_node.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/attr_in_item_not_impl.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/attr_in_item_not_impl.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_expr_error_incorrect_mut.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_expr_error_incorrect_mut.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_expr_error_incorrect_type.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_expr_error_incorrect_type.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_expr_error_incorrect_type_child.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_expr_error_incorrect_type_child.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_expr_error_no_field.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_expr_error_no_field.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_expr_no_children_field.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_expr_no_children_field.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_list_expr_error_incorrect_mut.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_list_expr_error_incorrect_mut.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_list_expr_error_incorrect_type.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_list_expr_error_incorrect_type.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_list_expr_error_incorrect_type_children.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/delegate_list_expr_error_incorrect_type_children.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/incorrect_assign_token.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/incorrect_assign_token.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/invalid_args.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/invalid_args.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/invalid_delegate_pair_name.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/invalid_delegate_pair_name.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/missing_delegate_expr.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/missing_delegate_expr.stderr (100%) rename tests/{build => macro-tests}/cases/ui_node/missing_matching_delegate_child.rs (100%) rename tests/{build => macro-tests}/cases/ui_node/missing_matching_delegate_child.stderr (100%) rename tests/{build => macro-tests}/cases/widget/cannot_instantiate_widget_mixin.rs (100%) rename tests/{build => macro-tests}/cases/widget/cannot_instantiate_widget_mixin.stderr (100%) rename tests/{build => macro-tests}/cases/widget/module_path_malformed2.rs (100%) rename tests/{build => macro-tests}/cases/widget/module_path_malformed2.stderr (100%) rename tests/{build => macro-tests}/cases/widget/module_path_malformed3.rs (100%) rename tests/{build => macro-tests}/cases/widget/module_path_malformed3.stderr (100%) rename tests/{build => macro-tests}/cases/widget/module_path_missing.rs (100%) rename tests/{build => macro-tests}/cases/widget/module_path_missing.stderr (100%) rename tests/{build => macro-tests}/cases/widget/module_path_missing_crate.rs (100%) rename tests/{build => macro-tests}/cases/widget/module_path_missing_crate.stderr (100%) rename tests/{build => macro-tests}/cases/widget/module_path_missing_dollar_sign.rs (100%) rename tests/{build => macro-tests}/cases/widget/module_path_missing_dollar_sign.stderr (100%) rename tests/{build => macro-tests}/cases/widget/name_conflict1.rs (100%) rename tests/{build => macro-tests}/cases/widget/name_conflict1.stderr (100%) rename tests/{build => macro-tests}/cases/widget/name_conflict2.rs (100%) rename tests/{build => macro-tests}/cases/widget/name_conflict2.stderr (100%) rename tests/{build => macro-tests}/cases/widget/parent_not_widget.rs (100%) rename tests/{build => macro-tests}/cases/widget/parent_not_widget.stderr (100%) rename tests/{build => macro-tests}/cases/widget/type_path_is_invalid1.rs (100%) rename tests/{build => macro-tests}/cases/widget/type_path_is_invalid1.stderr (100%) rename tests/{build => macro-tests}/cases/widget/type_path_malformed1.rs (100%) rename tests/{build => macro-tests}/cases/widget/type_path_malformed1.stderr (100%) rename tests/{build => macro-tests}/cases/widget/unknown_inherit.rs (100%) rename tests/{build => macro-tests}/cases/widget/unknown_inherit.stderr (100%) rename tests/{build => macro-tests}/cases/widget/util/a_mod.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/cannot_unset_in_when.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/cannot_unset_in_when.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/error_first_token.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/error_first_token.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/error_in_property_expr.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/error_in_property_expr.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/error_in_when_expr1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/error_in_when_expr1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/error_in_when_expr2.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/error_in_when_expr2.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/error_in_when_expr3.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/error_in_when_expr3.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_arg_type1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_arg_type1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_arg_type2.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_arg_type2.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_arg_type3.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_arg_type3.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_arg_type4.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_arg_type4.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_arg_type5.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_arg_type5.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_arg_type6.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_arg_type6.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_when_expr_type1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/incorrect_when_expr_type1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/invalid_special.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/invalid_special.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_fields1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_fields1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_fields2.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_fields2.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_property_attribute.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_property_attribute.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_property_path1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_property_path1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_property_path2.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_property_path2.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_property_path3.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_property_path3.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_property_path4.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/malformed_property_path4.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_arg1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_arg1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_field_all_multi.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_field_all_multi.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_field_all_single.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_field_all_single.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_field_multi.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_field_multi.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_semi1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_semi1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_semi2.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_semi2.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_semi_before_when1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_semi_before_when1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_semi_in_when1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_semi_in_when1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_semi_in_when2.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_semi_in_when2.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value2.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value2.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value3.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value3.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value4.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value4.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value5.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value5.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value6.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value6.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value_before_when1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/missing_value_before_when1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/not_allowed_in_when1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/not_allowed_in_when1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/not_allowed_in_when2.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/not_allowed_in_when2.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/property_generic1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/property_generic1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/property_generic2.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/property_generic2.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_field.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_field.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_member_in_when_expr1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_member_in_when_expr1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_member_in_when_expr2.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_member_in_when_expr2.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_property1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_property1.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_property2.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_property2.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_special_value.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_special_value.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_special_value_in_when.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/unknown_special_value_in_when.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/when_missing_block.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/when_missing_block.stderr (100%) rename tests/{build => macro-tests}/cases/widget_new/when_missing_expr1.rs (100%) rename tests/{build => macro-tests}/cases/widget_new/when_missing_expr1.stderr (100%) create mode 100644 tests/macro-tests/main.rs rename tests/{build => macro-tests}/run.rs (94%) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 66b5b98a7..f3dad909d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,24 +19,84 @@ env: RUSTDOCFLAGS: '--deny=warnings' jobs: - check: + prebuild: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 + - run: cargo do prebuild + - run: cargo clean + - uses: actions/upload-artifact@v1 + with: + name: prebuilt + path: zng-view-prebuilt/lib/libzng_view.so + check: + runs-on: ubuntu-latest + needs: [prebuild] + steps: + - uses: actions/checkout@v4 + - uses: actions/download-artifact@v1 + with: + name: prebuilt + path: zng-view-prebuilt/lib - run: cargo do version --verbose - run: cargo fmt -- --check - run: cargo do check doc: runs-on: ubuntu-latest + needs: [prebuild] steps: - uses: actions/checkout@v4 + - uses: actions/download-artifact@v1 + with: + name: prebuilt + path: zng-view-prebuilt/lib - run: cargo do doc - run: cargo clean test: runs-on: ubuntu-latest + needs: [prebuild] steps: - uses: actions/checkout@v4 - - run: cargo do prebuild - - run: cargo clean - - run: cargo do test + - uses: actions/download-artifact@v1 + with: + name: prebuilt + path: zng-view-prebuilt/lib + - run: cargo do test --lib --bins --tests - run: cargo clean + test-doc: + runs-on: ubuntu-latest + needs: [prebuild] + steps: + - uses: actions/checkout@v4 + - uses: actions/download-artifact@v1 + with: + name: prebuilt + path: zng-view-prebuilt/lib + - run: cargo do test --doc + - run: cargo clean + test-macro: + runs-on: ubuntu-latest + needs: [prebuild] + steps: + - uses: actions/checkout@v4 + - uses: actions/download-artifact@v1 + with: + name: prebuilt + path: zng-view-prebuilt/lib + - run: cargo do test --macro + - run: cargo clean + test-all: + runs-on: ubuntu-latest + needs: [check, doc, test, test-doc, test-macro] + steps: + - run: exit 0 + cleanup: + runs-on: ubuntu-latest + if: always() + needs: [test-all] + steps: + - uses: geekyeggo/delete-artifact@v5 + with: + name: prebuilt + failOnError: false + diff --git a/.github/workflows/release-1-test-tag.yml b/.github/workflows/release-1-test-tag.yml index 7d38809d4..f1122cc52 100644 --- a/.github/workflows/release-1-test-tag.yml +++ b/.github/workflows/release-1-test-tag.yml @@ -38,7 +38,11 @@ jobs: - run: cargo clean - run: cargo do doc - run: cargo clean - - run: cargo do test + - run: cargo do test --lib --bins --tests + - run: cargo clean + - run: cargo do test --doc + - run: cargo clean + - run: cargo do test --macro - run: cargo clean test-cargo-publish: diff --git a/.vscode/tasks.json b/.vscode/tasks.json index da3953c1a..5b4652829 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -73,23 +73,5 @@ }, "problemMatcher": [] } - ], - "inputs": [ - { - "id": "exampleNameID", - "description": "example name", - "type": "promptString", - }, - { - "id": "testGroupID", - "description": "test group", - "type": "pickString", - "options": [ - "--workspace", - "--doc", - "--test-crates", - "--build *" - ] - } ] } \ No newline at end of file diff --git a/Cargo.toml b/Cargo.toml index 5f7686a79..2a28662d9 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -86,7 +86,7 @@ members = [ # tests: "tests", - "tests/build", + "tests/macro-tests", ] [profile.dev] diff --git a/tests/README.md b/tests/README.md index 69d7f86c2..d78219c15 100644 --- a/tests/README.md +++ b/tests/README.md @@ -1,14 +1,14 @@ # Tests -Use this directory for integration, build tests or any test that is not a unit test. +Use this directory for integration, macro tests or any test that is not a unit test. # Running Use `cargo do test -t command` to run tests in the `./command.rs` file. -Use `cargo do test -b *` to run all build tests. +Use `cargo do test -m *` to run all macro tests. -Use `cargo do test -b property/*` to run build test cases that match the path relative to `./build/cases`. +Use `cargo do test -m property/*` to run build test cases that match the path relative to `./macro-tests/cases`. # Adding an Integration Test diff --git a/tests/build/main.rs b/tests/build/main.rs deleted file mode 100644 index efdb71b50..000000000 --- a/tests/build/main.rs +++ /dev/null @@ -1,9 +0,0 @@ -//! Use `cargo do test -b *` to run all build tests. -//! -//! Use `cargo do test -b property/*` to run all paths that match in the `./cases` folder. - -mod run; - -fn main() { - run::do_request(); -} diff --git a/tests/build/Cargo.toml b/tests/macro-tests/Cargo.toml similarity index 90% rename from tests/build/Cargo.toml rename to tests/macro-tests/Cargo.toml index c7612bdb2..c4786b8d0 100644 --- a/tests/build/Cargo.toml +++ b/tests/macro-tests/Cargo.toml @@ -1,5 +1,5 @@ [package] -name = "build-tests" +name = "macro-tests" version = "0.0.0" publish = false edition = "2021" diff --git a/tests/build/cases/property/args_count_no_input.rs b/tests/macro-tests/cases/property/args_count_no_input.rs similarity index 100% rename from tests/build/cases/property/args_count_no_input.rs rename to tests/macro-tests/cases/property/args_count_no_input.rs diff --git a/tests/build/cases/property/args_count_no_input.stderr b/tests/macro-tests/cases/property/args_count_no_input.stderr similarity index 100% rename from tests/build/cases/property/args_count_no_input.stderr rename to tests/macro-tests/cases/property/args_count_no_input.stderr diff --git a/tests/build/cases/property/args_count_none.rs b/tests/macro-tests/cases/property/args_count_none.rs similarity index 100% rename from tests/build/cases/property/args_count_none.rs rename to tests/macro-tests/cases/property/args_count_none.rs diff --git a/tests/build/cases/property/args_count_none.stderr b/tests/macro-tests/cases/property/args_count_none.stderr similarity index 100% rename from tests/build/cases/property/args_count_none.stderr rename to tests/macro-tests/cases/property/args_count_none.stderr diff --git a/tests/build/cases/property/cannot_declare_lifetime.rs b/tests/macro-tests/cases/property/cannot_declare_lifetime.rs similarity index 100% rename from tests/build/cases/property/cannot_declare_lifetime.rs rename to tests/macro-tests/cases/property/cannot_declare_lifetime.rs diff --git a/tests/build/cases/property/cannot_declare_lifetime.stderr b/tests/macro-tests/cases/property/cannot_declare_lifetime.stderr similarity index 100% rename from tests/build/cases/property/cannot_declare_lifetime.stderr rename to tests/macro-tests/cases/property/cannot_declare_lifetime.stderr diff --git a/tests/build/cases/property/child_type_constraints_ui_node.rs b/tests/macro-tests/cases/property/child_type_constraints_ui_node.rs similarity index 100% rename from tests/build/cases/property/child_type_constraints_ui_node.rs rename to tests/macro-tests/cases/property/child_type_constraints_ui_node.rs diff --git a/tests/build/cases/property/child_type_constraints_ui_node.stderr b/tests/macro-tests/cases/property/child_type_constraints_ui_node.stderr similarity index 100% rename from tests/build/cases/property/child_type_constraints_ui_node.stderr rename to tests/macro-tests/cases/property/child_type_constraints_ui_node.stderr diff --git a/tests/build/cases/property/child_type_is_not_ui_node.rs b/tests/macro-tests/cases/property/child_type_is_not_ui_node.rs similarity index 100% rename from tests/build/cases/property/child_type_is_not_ui_node.rs rename to tests/macro-tests/cases/property/child_type_is_not_ui_node.rs diff --git a/tests/build/cases/property/child_type_is_not_ui_node.stderr b/tests/macro-tests/cases/property/child_type_is_not_ui_node.stderr similarity index 100% rename from tests/build/cases/property/child_type_is_not_ui_node.stderr rename to tests/macro-tests/cases/property/child_type_is_not_ui_node.stderr diff --git a/tests/build/cases/property/defaults.rs b/tests/macro-tests/cases/property/defaults.rs similarity index 100% rename from tests/build/cases/property/defaults.rs rename to tests/macro-tests/cases/property/defaults.rs diff --git a/tests/build/cases/property/defaults.stderr b/tests/macro-tests/cases/property/defaults.stderr similarity index 100% rename from tests/build/cases/property/defaults.stderr rename to tests/macro-tests/cases/property/defaults.stderr diff --git a/tests/build/cases/property/incorrect_attr_args.rs b/tests/macro-tests/cases/property/incorrect_attr_args.rs similarity index 100% rename from tests/build/cases/property/incorrect_attr_args.rs rename to tests/macro-tests/cases/property/incorrect_attr_args.rs diff --git a/tests/build/cases/property/incorrect_attr_args.stderr b/tests/macro-tests/cases/property/incorrect_attr_args.stderr similarity index 100% rename from tests/build/cases/property/incorrect_attr_args.stderr rename to tests/macro-tests/cases/property/incorrect_attr_args.stderr diff --git a/tests/build/cases/property/invalid_function_qualifiers.rs b/tests/macro-tests/cases/property/invalid_function_qualifiers.rs similarity index 100% rename from tests/build/cases/property/invalid_function_qualifiers.rs rename to tests/macro-tests/cases/property/invalid_function_qualifiers.rs diff --git a/tests/build/cases/property/invalid_function_qualifiers.stderr b/tests/macro-tests/cases/property/invalid_function_qualifiers.stderr similarity index 100% rename from tests/build/cases/property/invalid_function_qualifiers.stderr rename to tests/macro-tests/cases/property/invalid_function_qualifiers.stderr diff --git a/tests/build/cases/property/invalid_input_pattern.rs b/tests/macro-tests/cases/property/invalid_input_pattern.rs similarity index 100% rename from tests/build/cases/property/invalid_input_pattern.rs rename to tests/macro-tests/cases/property/invalid_input_pattern.rs diff --git a/tests/build/cases/property/invalid_input_pattern.stderr b/tests/macro-tests/cases/property/invalid_input_pattern.stderr similarity index 100% rename from tests/build/cases/property/invalid_input_pattern.stderr rename to tests/macro-tests/cases/property/invalid_input_pattern.stderr diff --git a/tests/build/cases/property/invalid_priority.rs b/tests/macro-tests/cases/property/invalid_priority.rs similarity index 100% rename from tests/build/cases/property/invalid_priority.rs rename to tests/macro-tests/cases/property/invalid_priority.rs diff --git a/tests/build/cases/property/invalid_priority.stderr b/tests/macro-tests/cases/property/invalid_priority.stderr similarity index 100% rename from tests/build/cases/property/invalid_priority.stderr rename to tests/macro-tests/cases/property/invalid_priority.stderr diff --git a/tests/build/cases/property/method_cannot_be_property.rs b/tests/macro-tests/cases/property/method_cannot_be_property.rs similarity index 100% rename from tests/build/cases/property/method_cannot_be_property.rs rename to tests/macro-tests/cases/property/method_cannot_be_property.rs diff --git a/tests/build/cases/property/method_cannot_be_property.stderr b/tests/macro-tests/cases/property/method_cannot_be_property.stderr similarity index 100% rename from tests/build/cases/property/method_cannot_be_property.stderr rename to tests/macro-tests/cases/property/method_cannot_be_property.stderr diff --git a/tests/build/cases/property/prefix_get_default.rs b/tests/macro-tests/cases/property/prefix_get_default.rs similarity index 100% rename from tests/build/cases/property/prefix_get_default.rs rename to tests/macro-tests/cases/property/prefix_get_default.rs diff --git a/tests/build/cases/property/prefix_get_default.stderr b/tests/macro-tests/cases/property/prefix_get_default.stderr similarity index 100% rename from tests/build/cases/property/prefix_get_default.stderr rename to tests/macro-tests/cases/property/prefix_get_default.stderr diff --git a/tests/build/cases/property/prefix_has_default.rs b/tests/macro-tests/cases/property/prefix_has_default.rs similarity index 100% rename from tests/build/cases/property/prefix_has_default.rs rename to tests/macro-tests/cases/property/prefix_has_default.rs diff --git a/tests/build/cases/property/prefix_has_default.stderr b/tests/macro-tests/cases/property/prefix_has_default.stderr similarity index 100% rename from tests/build/cases/property/prefix_has_default.stderr rename to tests/macro-tests/cases/property/prefix_has_default.stderr diff --git a/tests/build/cases/property/prefix_is_default.rs b/tests/macro-tests/cases/property/prefix_is_default.rs similarity index 100% rename from tests/build/cases/property/prefix_is_default.rs rename to tests/macro-tests/cases/property/prefix_is_default.rs diff --git a/tests/build/cases/property/prefix_is_default.stderr b/tests/macro-tests/cases/property/prefix_is_default.stderr similarity index 100% rename from tests/build/cases/property/prefix_is_default.stderr rename to tests/macro-tests/cases/property/prefix_is_default.stderr diff --git a/tests/build/cases/property/property_attr_not_fn.rs b/tests/macro-tests/cases/property/property_attr_not_fn.rs similarity index 100% rename from tests/build/cases/property/property_attr_not_fn.rs rename to tests/macro-tests/cases/property/property_attr_not_fn.rs diff --git a/tests/build/cases/property/property_attr_not_fn.stderr b/tests/macro-tests/cases/property/property_attr_not_fn.stderr similarity index 100% rename from tests/build/cases/property/property_attr_not_fn.stderr rename to tests/macro-tests/cases/property/property_attr_not_fn.stderr diff --git a/tests/build/cases/property/return_type_is_not_ui_node.rs b/tests/macro-tests/cases/property/return_type_is_not_ui_node.rs similarity index 100% rename from tests/build/cases/property/return_type_is_not_ui_node.rs rename to tests/macro-tests/cases/property/return_type_is_not_ui_node.rs diff --git a/tests/build/cases/property/return_type_is_not_ui_node.stderr b/tests/macro-tests/cases/property/return_type_is_not_ui_node.stderr similarity index 100% rename from tests/build/cases/property/return_type_is_not_ui_node.stderr rename to tests/macro-tests/cases/property/return_type_is_not_ui_node.stderr diff --git a/tests/build/cases/ui_node/attr_in_item_not_impl.rs b/tests/macro-tests/cases/ui_node/attr_in_item_not_impl.rs similarity index 100% rename from tests/build/cases/ui_node/attr_in_item_not_impl.rs rename to tests/macro-tests/cases/ui_node/attr_in_item_not_impl.rs diff --git a/tests/build/cases/ui_node/attr_in_item_not_impl.stderr b/tests/macro-tests/cases/ui_node/attr_in_item_not_impl.stderr similarity index 100% rename from tests/build/cases/ui_node/attr_in_item_not_impl.stderr rename to tests/macro-tests/cases/ui_node/attr_in_item_not_impl.stderr diff --git a/tests/build/cases/ui_node/delegate_expr_error_incorrect_mut.rs b/tests/macro-tests/cases/ui_node/delegate_expr_error_incorrect_mut.rs similarity index 100% rename from tests/build/cases/ui_node/delegate_expr_error_incorrect_mut.rs rename to tests/macro-tests/cases/ui_node/delegate_expr_error_incorrect_mut.rs diff --git a/tests/build/cases/ui_node/delegate_expr_error_incorrect_mut.stderr b/tests/macro-tests/cases/ui_node/delegate_expr_error_incorrect_mut.stderr similarity index 100% rename from tests/build/cases/ui_node/delegate_expr_error_incorrect_mut.stderr rename to tests/macro-tests/cases/ui_node/delegate_expr_error_incorrect_mut.stderr diff --git a/tests/build/cases/ui_node/delegate_expr_error_incorrect_type.rs b/tests/macro-tests/cases/ui_node/delegate_expr_error_incorrect_type.rs similarity index 100% rename from tests/build/cases/ui_node/delegate_expr_error_incorrect_type.rs rename to tests/macro-tests/cases/ui_node/delegate_expr_error_incorrect_type.rs diff --git a/tests/build/cases/ui_node/delegate_expr_error_incorrect_type.stderr b/tests/macro-tests/cases/ui_node/delegate_expr_error_incorrect_type.stderr similarity index 100% rename from tests/build/cases/ui_node/delegate_expr_error_incorrect_type.stderr rename to tests/macro-tests/cases/ui_node/delegate_expr_error_incorrect_type.stderr diff --git a/tests/build/cases/ui_node/delegate_expr_error_incorrect_type_child.rs b/tests/macro-tests/cases/ui_node/delegate_expr_error_incorrect_type_child.rs similarity index 100% rename from tests/build/cases/ui_node/delegate_expr_error_incorrect_type_child.rs rename to tests/macro-tests/cases/ui_node/delegate_expr_error_incorrect_type_child.rs diff --git a/tests/build/cases/ui_node/delegate_expr_error_incorrect_type_child.stderr b/tests/macro-tests/cases/ui_node/delegate_expr_error_incorrect_type_child.stderr similarity index 100% rename from tests/build/cases/ui_node/delegate_expr_error_incorrect_type_child.stderr rename to tests/macro-tests/cases/ui_node/delegate_expr_error_incorrect_type_child.stderr diff --git a/tests/build/cases/ui_node/delegate_expr_error_no_field.rs b/tests/macro-tests/cases/ui_node/delegate_expr_error_no_field.rs similarity index 100% rename from tests/build/cases/ui_node/delegate_expr_error_no_field.rs rename to tests/macro-tests/cases/ui_node/delegate_expr_error_no_field.rs diff --git a/tests/build/cases/ui_node/delegate_expr_error_no_field.stderr b/tests/macro-tests/cases/ui_node/delegate_expr_error_no_field.stderr similarity index 100% rename from tests/build/cases/ui_node/delegate_expr_error_no_field.stderr rename to tests/macro-tests/cases/ui_node/delegate_expr_error_no_field.stderr diff --git a/tests/build/cases/ui_node/delegate_expr_no_children_field.rs b/tests/macro-tests/cases/ui_node/delegate_expr_no_children_field.rs similarity index 100% rename from tests/build/cases/ui_node/delegate_expr_no_children_field.rs rename to tests/macro-tests/cases/ui_node/delegate_expr_no_children_field.rs diff --git a/tests/build/cases/ui_node/delegate_expr_no_children_field.stderr b/tests/macro-tests/cases/ui_node/delegate_expr_no_children_field.stderr similarity index 100% rename from tests/build/cases/ui_node/delegate_expr_no_children_field.stderr rename to tests/macro-tests/cases/ui_node/delegate_expr_no_children_field.stderr diff --git a/tests/build/cases/ui_node/delegate_list_expr_error_incorrect_mut.rs b/tests/macro-tests/cases/ui_node/delegate_list_expr_error_incorrect_mut.rs similarity index 100% rename from tests/build/cases/ui_node/delegate_list_expr_error_incorrect_mut.rs rename to tests/macro-tests/cases/ui_node/delegate_list_expr_error_incorrect_mut.rs diff --git a/tests/build/cases/ui_node/delegate_list_expr_error_incorrect_mut.stderr b/tests/macro-tests/cases/ui_node/delegate_list_expr_error_incorrect_mut.stderr similarity index 100% rename from tests/build/cases/ui_node/delegate_list_expr_error_incorrect_mut.stderr rename to tests/macro-tests/cases/ui_node/delegate_list_expr_error_incorrect_mut.stderr diff --git a/tests/build/cases/ui_node/delegate_list_expr_error_incorrect_type.rs b/tests/macro-tests/cases/ui_node/delegate_list_expr_error_incorrect_type.rs similarity index 100% rename from tests/build/cases/ui_node/delegate_list_expr_error_incorrect_type.rs rename to tests/macro-tests/cases/ui_node/delegate_list_expr_error_incorrect_type.rs diff --git a/tests/build/cases/ui_node/delegate_list_expr_error_incorrect_type.stderr b/tests/macro-tests/cases/ui_node/delegate_list_expr_error_incorrect_type.stderr similarity index 100% rename from tests/build/cases/ui_node/delegate_list_expr_error_incorrect_type.stderr rename to tests/macro-tests/cases/ui_node/delegate_list_expr_error_incorrect_type.stderr diff --git a/tests/build/cases/ui_node/delegate_list_expr_error_incorrect_type_children.rs b/tests/macro-tests/cases/ui_node/delegate_list_expr_error_incorrect_type_children.rs similarity index 100% rename from tests/build/cases/ui_node/delegate_list_expr_error_incorrect_type_children.rs rename to tests/macro-tests/cases/ui_node/delegate_list_expr_error_incorrect_type_children.rs diff --git a/tests/build/cases/ui_node/delegate_list_expr_error_incorrect_type_children.stderr b/tests/macro-tests/cases/ui_node/delegate_list_expr_error_incorrect_type_children.stderr similarity index 100% rename from tests/build/cases/ui_node/delegate_list_expr_error_incorrect_type_children.stderr rename to tests/macro-tests/cases/ui_node/delegate_list_expr_error_incorrect_type_children.stderr diff --git a/tests/build/cases/ui_node/incorrect_assign_token.rs b/tests/macro-tests/cases/ui_node/incorrect_assign_token.rs similarity index 100% rename from tests/build/cases/ui_node/incorrect_assign_token.rs rename to tests/macro-tests/cases/ui_node/incorrect_assign_token.rs diff --git a/tests/build/cases/ui_node/incorrect_assign_token.stderr b/tests/macro-tests/cases/ui_node/incorrect_assign_token.stderr similarity index 100% rename from tests/build/cases/ui_node/incorrect_assign_token.stderr rename to tests/macro-tests/cases/ui_node/incorrect_assign_token.stderr diff --git a/tests/build/cases/ui_node/invalid_args.rs b/tests/macro-tests/cases/ui_node/invalid_args.rs similarity index 100% rename from tests/build/cases/ui_node/invalid_args.rs rename to tests/macro-tests/cases/ui_node/invalid_args.rs diff --git a/tests/build/cases/ui_node/invalid_args.stderr b/tests/macro-tests/cases/ui_node/invalid_args.stderr similarity index 100% rename from tests/build/cases/ui_node/invalid_args.stderr rename to tests/macro-tests/cases/ui_node/invalid_args.stderr diff --git a/tests/build/cases/ui_node/invalid_delegate_pair_name.rs b/tests/macro-tests/cases/ui_node/invalid_delegate_pair_name.rs similarity index 100% rename from tests/build/cases/ui_node/invalid_delegate_pair_name.rs rename to tests/macro-tests/cases/ui_node/invalid_delegate_pair_name.rs diff --git a/tests/build/cases/ui_node/invalid_delegate_pair_name.stderr b/tests/macro-tests/cases/ui_node/invalid_delegate_pair_name.stderr similarity index 100% rename from tests/build/cases/ui_node/invalid_delegate_pair_name.stderr rename to tests/macro-tests/cases/ui_node/invalid_delegate_pair_name.stderr diff --git a/tests/build/cases/ui_node/missing_delegate_expr.rs b/tests/macro-tests/cases/ui_node/missing_delegate_expr.rs similarity index 100% rename from tests/build/cases/ui_node/missing_delegate_expr.rs rename to tests/macro-tests/cases/ui_node/missing_delegate_expr.rs diff --git a/tests/build/cases/ui_node/missing_delegate_expr.stderr b/tests/macro-tests/cases/ui_node/missing_delegate_expr.stderr similarity index 100% rename from tests/build/cases/ui_node/missing_delegate_expr.stderr rename to tests/macro-tests/cases/ui_node/missing_delegate_expr.stderr diff --git a/tests/build/cases/ui_node/missing_matching_delegate_child.rs b/tests/macro-tests/cases/ui_node/missing_matching_delegate_child.rs similarity index 100% rename from tests/build/cases/ui_node/missing_matching_delegate_child.rs rename to tests/macro-tests/cases/ui_node/missing_matching_delegate_child.rs diff --git a/tests/build/cases/ui_node/missing_matching_delegate_child.stderr b/tests/macro-tests/cases/ui_node/missing_matching_delegate_child.stderr similarity index 100% rename from tests/build/cases/ui_node/missing_matching_delegate_child.stderr rename to tests/macro-tests/cases/ui_node/missing_matching_delegate_child.stderr diff --git a/tests/build/cases/widget/cannot_instantiate_widget_mixin.rs b/tests/macro-tests/cases/widget/cannot_instantiate_widget_mixin.rs similarity index 100% rename from tests/build/cases/widget/cannot_instantiate_widget_mixin.rs rename to tests/macro-tests/cases/widget/cannot_instantiate_widget_mixin.rs diff --git a/tests/build/cases/widget/cannot_instantiate_widget_mixin.stderr b/tests/macro-tests/cases/widget/cannot_instantiate_widget_mixin.stderr similarity index 100% rename from tests/build/cases/widget/cannot_instantiate_widget_mixin.stderr rename to tests/macro-tests/cases/widget/cannot_instantiate_widget_mixin.stderr diff --git a/tests/build/cases/widget/module_path_malformed2.rs b/tests/macro-tests/cases/widget/module_path_malformed2.rs similarity index 100% rename from tests/build/cases/widget/module_path_malformed2.rs rename to tests/macro-tests/cases/widget/module_path_malformed2.rs diff --git a/tests/build/cases/widget/module_path_malformed2.stderr b/tests/macro-tests/cases/widget/module_path_malformed2.stderr similarity index 100% rename from tests/build/cases/widget/module_path_malformed2.stderr rename to tests/macro-tests/cases/widget/module_path_malformed2.stderr diff --git a/tests/build/cases/widget/module_path_malformed3.rs b/tests/macro-tests/cases/widget/module_path_malformed3.rs similarity index 100% rename from tests/build/cases/widget/module_path_malformed3.rs rename to tests/macro-tests/cases/widget/module_path_malformed3.rs diff --git a/tests/build/cases/widget/module_path_malformed3.stderr b/tests/macro-tests/cases/widget/module_path_malformed3.stderr similarity index 100% rename from tests/build/cases/widget/module_path_malformed3.stderr rename to tests/macro-tests/cases/widget/module_path_malformed3.stderr diff --git a/tests/build/cases/widget/module_path_missing.rs b/tests/macro-tests/cases/widget/module_path_missing.rs similarity index 100% rename from tests/build/cases/widget/module_path_missing.rs rename to tests/macro-tests/cases/widget/module_path_missing.rs diff --git a/tests/build/cases/widget/module_path_missing.stderr b/tests/macro-tests/cases/widget/module_path_missing.stderr similarity index 100% rename from tests/build/cases/widget/module_path_missing.stderr rename to tests/macro-tests/cases/widget/module_path_missing.stderr diff --git a/tests/build/cases/widget/module_path_missing_crate.rs b/tests/macro-tests/cases/widget/module_path_missing_crate.rs similarity index 100% rename from tests/build/cases/widget/module_path_missing_crate.rs rename to tests/macro-tests/cases/widget/module_path_missing_crate.rs diff --git a/tests/build/cases/widget/module_path_missing_crate.stderr b/tests/macro-tests/cases/widget/module_path_missing_crate.stderr similarity index 100% rename from tests/build/cases/widget/module_path_missing_crate.stderr rename to tests/macro-tests/cases/widget/module_path_missing_crate.stderr diff --git a/tests/build/cases/widget/module_path_missing_dollar_sign.rs b/tests/macro-tests/cases/widget/module_path_missing_dollar_sign.rs similarity index 100% rename from tests/build/cases/widget/module_path_missing_dollar_sign.rs rename to tests/macro-tests/cases/widget/module_path_missing_dollar_sign.rs diff --git a/tests/build/cases/widget/module_path_missing_dollar_sign.stderr b/tests/macro-tests/cases/widget/module_path_missing_dollar_sign.stderr similarity index 100% rename from tests/build/cases/widget/module_path_missing_dollar_sign.stderr rename to tests/macro-tests/cases/widget/module_path_missing_dollar_sign.stderr diff --git a/tests/build/cases/widget/name_conflict1.rs b/tests/macro-tests/cases/widget/name_conflict1.rs similarity index 100% rename from tests/build/cases/widget/name_conflict1.rs rename to tests/macro-tests/cases/widget/name_conflict1.rs diff --git a/tests/build/cases/widget/name_conflict1.stderr b/tests/macro-tests/cases/widget/name_conflict1.stderr similarity index 100% rename from tests/build/cases/widget/name_conflict1.stderr rename to tests/macro-tests/cases/widget/name_conflict1.stderr diff --git a/tests/build/cases/widget/name_conflict2.rs b/tests/macro-tests/cases/widget/name_conflict2.rs similarity index 100% rename from tests/build/cases/widget/name_conflict2.rs rename to tests/macro-tests/cases/widget/name_conflict2.rs diff --git a/tests/build/cases/widget/name_conflict2.stderr b/tests/macro-tests/cases/widget/name_conflict2.stderr similarity index 100% rename from tests/build/cases/widget/name_conflict2.stderr rename to tests/macro-tests/cases/widget/name_conflict2.stderr diff --git a/tests/build/cases/widget/parent_not_widget.rs b/tests/macro-tests/cases/widget/parent_not_widget.rs similarity index 100% rename from tests/build/cases/widget/parent_not_widget.rs rename to tests/macro-tests/cases/widget/parent_not_widget.rs diff --git a/tests/build/cases/widget/parent_not_widget.stderr b/tests/macro-tests/cases/widget/parent_not_widget.stderr similarity index 100% rename from tests/build/cases/widget/parent_not_widget.stderr rename to tests/macro-tests/cases/widget/parent_not_widget.stderr diff --git a/tests/build/cases/widget/type_path_is_invalid1.rs b/tests/macro-tests/cases/widget/type_path_is_invalid1.rs similarity index 100% rename from tests/build/cases/widget/type_path_is_invalid1.rs rename to tests/macro-tests/cases/widget/type_path_is_invalid1.rs diff --git a/tests/build/cases/widget/type_path_is_invalid1.stderr b/tests/macro-tests/cases/widget/type_path_is_invalid1.stderr similarity index 100% rename from tests/build/cases/widget/type_path_is_invalid1.stderr rename to tests/macro-tests/cases/widget/type_path_is_invalid1.stderr diff --git a/tests/build/cases/widget/type_path_malformed1.rs b/tests/macro-tests/cases/widget/type_path_malformed1.rs similarity index 100% rename from tests/build/cases/widget/type_path_malformed1.rs rename to tests/macro-tests/cases/widget/type_path_malformed1.rs diff --git a/tests/build/cases/widget/type_path_malformed1.stderr b/tests/macro-tests/cases/widget/type_path_malformed1.stderr similarity index 100% rename from tests/build/cases/widget/type_path_malformed1.stderr rename to tests/macro-tests/cases/widget/type_path_malformed1.stderr diff --git a/tests/build/cases/widget/unknown_inherit.rs b/tests/macro-tests/cases/widget/unknown_inherit.rs similarity index 100% rename from tests/build/cases/widget/unknown_inherit.rs rename to tests/macro-tests/cases/widget/unknown_inherit.rs diff --git a/tests/build/cases/widget/unknown_inherit.stderr b/tests/macro-tests/cases/widget/unknown_inherit.stderr similarity index 100% rename from tests/build/cases/widget/unknown_inherit.stderr rename to tests/macro-tests/cases/widget/unknown_inherit.stderr diff --git a/tests/build/cases/widget/util/a_mod.rs b/tests/macro-tests/cases/widget/util/a_mod.rs similarity index 100% rename from tests/build/cases/widget/util/a_mod.rs rename to tests/macro-tests/cases/widget/util/a_mod.rs diff --git a/tests/build/cases/widget_new/cannot_unset_in_when.rs b/tests/macro-tests/cases/widget_new/cannot_unset_in_when.rs similarity index 100% rename from tests/build/cases/widget_new/cannot_unset_in_when.rs rename to tests/macro-tests/cases/widget_new/cannot_unset_in_when.rs diff --git a/tests/build/cases/widget_new/cannot_unset_in_when.stderr b/tests/macro-tests/cases/widget_new/cannot_unset_in_when.stderr similarity index 100% rename from tests/build/cases/widget_new/cannot_unset_in_when.stderr rename to tests/macro-tests/cases/widget_new/cannot_unset_in_when.stderr diff --git a/tests/build/cases/widget_new/error_first_token.rs b/tests/macro-tests/cases/widget_new/error_first_token.rs similarity index 100% rename from tests/build/cases/widget_new/error_first_token.rs rename to tests/macro-tests/cases/widget_new/error_first_token.rs diff --git a/tests/build/cases/widget_new/error_first_token.stderr b/tests/macro-tests/cases/widget_new/error_first_token.stderr similarity index 100% rename from tests/build/cases/widget_new/error_first_token.stderr rename to tests/macro-tests/cases/widget_new/error_first_token.stderr diff --git a/tests/build/cases/widget_new/error_in_property_expr.rs b/tests/macro-tests/cases/widget_new/error_in_property_expr.rs similarity index 100% rename from tests/build/cases/widget_new/error_in_property_expr.rs rename to tests/macro-tests/cases/widget_new/error_in_property_expr.rs diff --git a/tests/build/cases/widget_new/error_in_property_expr.stderr b/tests/macro-tests/cases/widget_new/error_in_property_expr.stderr similarity index 100% rename from tests/build/cases/widget_new/error_in_property_expr.stderr rename to tests/macro-tests/cases/widget_new/error_in_property_expr.stderr diff --git a/tests/build/cases/widget_new/error_in_when_expr1.rs b/tests/macro-tests/cases/widget_new/error_in_when_expr1.rs similarity index 100% rename from tests/build/cases/widget_new/error_in_when_expr1.rs rename to tests/macro-tests/cases/widget_new/error_in_when_expr1.rs diff --git a/tests/build/cases/widget_new/error_in_when_expr1.stderr b/tests/macro-tests/cases/widget_new/error_in_when_expr1.stderr similarity index 100% rename from tests/build/cases/widget_new/error_in_when_expr1.stderr rename to tests/macro-tests/cases/widget_new/error_in_when_expr1.stderr diff --git a/tests/build/cases/widget_new/error_in_when_expr2.rs b/tests/macro-tests/cases/widget_new/error_in_when_expr2.rs similarity index 100% rename from tests/build/cases/widget_new/error_in_when_expr2.rs rename to tests/macro-tests/cases/widget_new/error_in_when_expr2.rs diff --git a/tests/build/cases/widget_new/error_in_when_expr2.stderr b/tests/macro-tests/cases/widget_new/error_in_when_expr2.stderr similarity index 100% rename from tests/build/cases/widget_new/error_in_when_expr2.stderr rename to tests/macro-tests/cases/widget_new/error_in_when_expr2.stderr diff --git a/tests/build/cases/widget_new/error_in_when_expr3.rs b/tests/macro-tests/cases/widget_new/error_in_when_expr3.rs similarity index 100% rename from tests/build/cases/widget_new/error_in_when_expr3.rs rename to tests/macro-tests/cases/widget_new/error_in_when_expr3.rs diff --git a/tests/build/cases/widget_new/error_in_when_expr3.stderr b/tests/macro-tests/cases/widget_new/error_in_when_expr3.stderr similarity index 100% rename from tests/build/cases/widget_new/error_in_when_expr3.stderr rename to tests/macro-tests/cases/widget_new/error_in_when_expr3.stderr diff --git a/tests/build/cases/widget_new/incorrect_arg_type1.rs b/tests/macro-tests/cases/widget_new/incorrect_arg_type1.rs similarity index 100% rename from tests/build/cases/widget_new/incorrect_arg_type1.rs rename to tests/macro-tests/cases/widget_new/incorrect_arg_type1.rs diff --git a/tests/build/cases/widget_new/incorrect_arg_type1.stderr b/tests/macro-tests/cases/widget_new/incorrect_arg_type1.stderr similarity index 100% rename from tests/build/cases/widget_new/incorrect_arg_type1.stderr rename to tests/macro-tests/cases/widget_new/incorrect_arg_type1.stderr diff --git a/tests/build/cases/widget_new/incorrect_arg_type2.rs b/tests/macro-tests/cases/widget_new/incorrect_arg_type2.rs similarity index 100% rename from tests/build/cases/widget_new/incorrect_arg_type2.rs rename to tests/macro-tests/cases/widget_new/incorrect_arg_type2.rs diff --git a/tests/build/cases/widget_new/incorrect_arg_type2.stderr b/tests/macro-tests/cases/widget_new/incorrect_arg_type2.stderr similarity index 100% rename from tests/build/cases/widget_new/incorrect_arg_type2.stderr rename to tests/macro-tests/cases/widget_new/incorrect_arg_type2.stderr diff --git a/tests/build/cases/widget_new/incorrect_arg_type3.rs b/tests/macro-tests/cases/widget_new/incorrect_arg_type3.rs similarity index 100% rename from tests/build/cases/widget_new/incorrect_arg_type3.rs rename to tests/macro-tests/cases/widget_new/incorrect_arg_type3.rs diff --git a/tests/build/cases/widget_new/incorrect_arg_type3.stderr b/tests/macro-tests/cases/widget_new/incorrect_arg_type3.stderr similarity index 100% rename from tests/build/cases/widget_new/incorrect_arg_type3.stderr rename to tests/macro-tests/cases/widget_new/incorrect_arg_type3.stderr diff --git a/tests/build/cases/widget_new/incorrect_arg_type4.rs b/tests/macro-tests/cases/widget_new/incorrect_arg_type4.rs similarity index 100% rename from tests/build/cases/widget_new/incorrect_arg_type4.rs rename to tests/macro-tests/cases/widget_new/incorrect_arg_type4.rs diff --git a/tests/build/cases/widget_new/incorrect_arg_type4.stderr b/tests/macro-tests/cases/widget_new/incorrect_arg_type4.stderr similarity index 100% rename from tests/build/cases/widget_new/incorrect_arg_type4.stderr rename to tests/macro-tests/cases/widget_new/incorrect_arg_type4.stderr diff --git a/tests/build/cases/widget_new/incorrect_arg_type5.rs b/tests/macro-tests/cases/widget_new/incorrect_arg_type5.rs similarity index 100% rename from tests/build/cases/widget_new/incorrect_arg_type5.rs rename to tests/macro-tests/cases/widget_new/incorrect_arg_type5.rs diff --git a/tests/build/cases/widget_new/incorrect_arg_type5.stderr b/tests/macro-tests/cases/widget_new/incorrect_arg_type5.stderr similarity index 100% rename from tests/build/cases/widget_new/incorrect_arg_type5.stderr rename to tests/macro-tests/cases/widget_new/incorrect_arg_type5.stderr diff --git a/tests/build/cases/widget_new/incorrect_arg_type6.rs b/tests/macro-tests/cases/widget_new/incorrect_arg_type6.rs similarity index 100% rename from tests/build/cases/widget_new/incorrect_arg_type6.rs rename to tests/macro-tests/cases/widget_new/incorrect_arg_type6.rs diff --git a/tests/build/cases/widget_new/incorrect_arg_type6.stderr b/tests/macro-tests/cases/widget_new/incorrect_arg_type6.stderr similarity index 100% rename from tests/build/cases/widget_new/incorrect_arg_type6.stderr rename to tests/macro-tests/cases/widget_new/incorrect_arg_type6.stderr diff --git a/tests/build/cases/widget_new/incorrect_when_expr_type1.rs b/tests/macro-tests/cases/widget_new/incorrect_when_expr_type1.rs similarity index 100% rename from tests/build/cases/widget_new/incorrect_when_expr_type1.rs rename to tests/macro-tests/cases/widget_new/incorrect_when_expr_type1.rs diff --git a/tests/build/cases/widget_new/incorrect_when_expr_type1.stderr b/tests/macro-tests/cases/widget_new/incorrect_when_expr_type1.stderr similarity index 100% rename from tests/build/cases/widget_new/incorrect_when_expr_type1.stderr rename to tests/macro-tests/cases/widget_new/incorrect_when_expr_type1.stderr diff --git a/tests/build/cases/widget_new/invalid_special.rs b/tests/macro-tests/cases/widget_new/invalid_special.rs similarity index 100% rename from tests/build/cases/widget_new/invalid_special.rs rename to tests/macro-tests/cases/widget_new/invalid_special.rs diff --git a/tests/build/cases/widget_new/invalid_special.stderr b/tests/macro-tests/cases/widget_new/invalid_special.stderr similarity index 100% rename from tests/build/cases/widget_new/invalid_special.stderr rename to tests/macro-tests/cases/widget_new/invalid_special.stderr diff --git a/tests/build/cases/widget_new/malformed_fields1.rs b/tests/macro-tests/cases/widget_new/malformed_fields1.rs similarity index 100% rename from tests/build/cases/widget_new/malformed_fields1.rs rename to tests/macro-tests/cases/widget_new/malformed_fields1.rs diff --git a/tests/build/cases/widget_new/malformed_fields1.stderr b/tests/macro-tests/cases/widget_new/malformed_fields1.stderr similarity index 100% rename from tests/build/cases/widget_new/malformed_fields1.stderr rename to tests/macro-tests/cases/widget_new/malformed_fields1.stderr diff --git a/tests/build/cases/widget_new/malformed_fields2.rs b/tests/macro-tests/cases/widget_new/malformed_fields2.rs similarity index 100% rename from tests/build/cases/widget_new/malformed_fields2.rs rename to tests/macro-tests/cases/widget_new/malformed_fields2.rs diff --git a/tests/build/cases/widget_new/malformed_fields2.stderr b/tests/macro-tests/cases/widget_new/malformed_fields2.stderr similarity index 100% rename from tests/build/cases/widget_new/malformed_fields2.stderr rename to tests/macro-tests/cases/widget_new/malformed_fields2.stderr diff --git a/tests/build/cases/widget_new/malformed_property_attribute.rs b/tests/macro-tests/cases/widget_new/malformed_property_attribute.rs similarity index 100% rename from tests/build/cases/widget_new/malformed_property_attribute.rs rename to tests/macro-tests/cases/widget_new/malformed_property_attribute.rs diff --git a/tests/build/cases/widget_new/malformed_property_attribute.stderr b/tests/macro-tests/cases/widget_new/malformed_property_attribute.stderr similarity index 100% rename from tests/build/cases/widget_new/malformed_property_attribute.stderr rename to tests/macro-tests/cases/widget_new/malformed_property_attribute.stderr diff --git a/tests/build/cases/widget_new/malformed_property_path1.rs b/tests/macro-tests/cases/widget_new/malformed_property_path1.rs similarity index 100% rename from tests/build/cases/widget_new/malformed_property_path1.rs rename to tests/macro-tests/cases/widget_new/malformed_property_path1.rs diff --git a/tests/build/cases/widget_new/malformed_property_path1.stderr b/tests/macro-tests/cases/widget_new/malformed_property_path1.stderr similarity index 100% rename from tests/build/cases/widget_new/malformed_property_path1.stderr rename to tests/macro-tests/cases/widget_new/malformed_property_path1.stderr diff --git a/tests/build/cases/widget_new/malformed_property_path2.rs b/tests/macro-tests/cases/widget_new/malformed_property_path2.rs similarity index 100% rename from tests/build/cases/widget_new/malformed_property_path2.rs rename to tests/macro-tests/cases/widget_new/malformed_property_path2.rs diff --git a/tests/build/cases/widget_new/malformed_property_path2.stderr b/tests/macro-tests/cases/widget_new/malformed_property_path2.stderr similarity index 100% rename from tests/build/cases/widget_new/malformed_property_path2.stderr rename to tests/macro-tests/cases/widget_new/malformed_property_path2.stderr diff --git a/tests/build/cases/widget_new/malformed_property_path3.rs b/tests/macro-tests/cases/widget_new/malformed_property_path3.rs similarity index 100% rename from tests/build/cases/widget_new/malformed_property_path3.rs rename to tests/macro-tests/cases/widget_new/malformed_property_path3.rs diff --git a/tests/build/cases/widget_new/malformed_property_path3.stderr b/tests/macro-tests/cases/widget_new/malformed_property_path3.stderr similarity index 100% rename from tests/build/cases/widget_new/malformed_property_path3.stderr rename to tests/macro-tests/cases/widget_new/malformed_property_path3.stderr diff --git a/tests/build/cases/widget_new/malformed_property_path4.rs b/tests/macro-tests/cases/widget_new/malformed_property_path4.rs similarity index 100% rename from tests/build/cases/widget_new/malformed_property_path4.rs rename to tests/macro-tests/cases/widget_new/malformed_property_path4.rs diff --git a/tests/build/cases/widget_new/malformed_property_path4.stderr b/tests/macro-tests/cases/widget_new/malformed_property_path4.stderr similarity index 100% rename from tests/build/cases/widget_new/malformed_property_path4.stderr rename to tests/macro-tests/cases/widget_new/malformed_property_path4.stderr diff --git a/tests/build/cases/widget_new/missing_arg1.rs b/tests/macro-tests/cases/widget_new/missing_arg1.rs similarity index 100% rename from tests/build/cases/widget_new/missing_arg1.rs rename to tests/macro-tests/cases/widget_new/missing_arg1.rs diff --git a/tests/build/cases/widget_new/missing_arg1.stderr b/tests/macro-tests/cases/widget_new/missing_arg1.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_arg1.stderr rename to tests/macro-tests/cases/widget_new/missing_arg1.stderr diff --git a/tests/build/cases/widget_new/missing_field_all_multi.rs b/tests/macro-tests/cases/widget_new/missing_field_all_multi.rs similarity index 100% rename from tests/build/cases/widget_new/missing_field_all_multi.rs rename to tests/macro-tests/cases/widget_new/missing_field_all_multi.rs diff --git a/tests/build/cases/widget_new/missing_field_all_multi.stderr b/tests/macro-tests/cases/widget_new/missing_field_all_multi.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_field_all_multi.stderr rename to tests/macro-tests/cases/widget_new/missing_field_all_multi.stderr diff --git a/tests/build/cases/widget_new/missing_field_all_single.rs b/tests/macro-tests/cases/widget_new/missing_field_all_single.rs similarity index 100% rename from tests/build/cases/widget_new/missing_field_all_single.rs rename to tests/macro-tests/cases/widget_new/missing_field_all_single.rs diff --git a/tests/build/cases/widget_new/missing_field_all_single.stderr b/tests/macro-tests/cases/widget_new/missing_field_all_single.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_field_all_single.stderr rename to tests/macro-tests/cases/widget_new/missing_field_all_single.stderr diff --git a/tests/build/cases/widget_new/missing_field_multi.rs b/tests/macro-tests/cases/widget_new/missing_field_multi.rs similarity index 100% rename from tests/build/cases/widget_new/missing_field_multi.rs rename to tests/macro-tests/cases/widget_new/missing_field_multi.rs diff --git a/tests/build/cases/widget_new/missing_field_multi.stderr b/tests/macro-tests/cases/widget_new/missing_field_multi.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_field_multi.stderr rename to tests/macro-tests/cases/widget_new/missing_field_multi.stderr diff --git a/tests/build/cases/widget_new/missing_semi1.rs b/tests/macro-tests/cases/widget_new/missing_semi1.rs similarity index 100% rename from tests/build/cases/widget_new/missing_semi1.rs rename to tests/macro-tests/cases/widget_new/missing_semi1.rs diff --git a/tests/build/cases/widget_new/missing_semi1.stderr b/tests/macro-tests/cases/widget_new/missing_semi1.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_semi1.stderr rename to tests/macro-tests/cases/widget_new/missing_semi1.stderr diff --git a/tests/build/cases/widget_new/missing_semi2.rs b/tests/macro-tests/cases/widget_new/missing_semi2.rs similarity index 100% rename from tests/build/cases/widget_new/missing_semi2.rs rename to tests/macro-tests/cases/widget_new/missing_semi2.rs diff --git a/tests/build/cases/widget_new/missing_semi2.stderr b/tests/macro-tests/cases/widget_new/missing_semi2.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_semi2.stderr rename to tests/macro-tests/cases/widget_new/missing_semi2.stderr diff --git a/tests/build/cases/widget_new/missing_semi_before_when1.rs b/tests/macro-tests/cases/widget_new/missing_semi_before_when1.rs similarity index 100% rename from tests/build/cases/widget_new/missing_semi_before_when1.rs rename to tests/macro-tests/cases/widget_new/missing_semi_before_when1.rs diff --git a/tests/build/cases/widget_new/missing_semi_before_when1.stderr b/tests/macro-tests/cases/widget_new/missing_semi_before_when1.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_semi_before_when1.stderr rename to tests/macro-tests/cases/widget_new/missing_semi_before_when1.stderr diff --git a/tests/build/cases/widget_new/missing_semi_in_when1.rs b/tests/macro-tests/cases/widget_new/missing_semi_in_when1.rs similarity index 100% rename from tests/build/cases/widget_new/missing_semi_in_when1.rs rename to tests/macro-tests/cases/widget_new/missing_semi_in_when1.rs diff --git a/tests/build/cases/widget_new/missing_semi_in_when1.stderr b/tests/macro-tests/cases/widget_new/missing_semi_in_when1.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_semi_in_when1.stderr rename to tests/macro-tests/cases/widget_new/missing_semi_in_when1.stderr diff --git a/tests/build/cases/widget_new/missing_semi_in_when2.rs b/tests/macro-tests/cases/widget_new/missing_semi_in_when2.rs similarity index 100% rename from tests/build/cases/widget_new/missing_semi_in_when2.rs rename to tests/macro-tests/cases/widget_new/missing_semi_in_when2.rs diff --git a/tests/build/cases/widget_new/missing_semi_in_when2.stderr b/tests/macro-tests/cases/widget_new/missing_semi_in_when2.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_semi_in_when2.stderr rename to tests/macro-tests/cases/widget_new/missing_semi_in_when2.stderr diff --git a/tests/build/cases/widget_new/missing_value1.rs b/tests/macro-tests/cases/widget_new/missing_value1.rs similarity index 100% rename from tests/build/cases/widget_new/missing_value1.rs rename to tests/macro-tests/cases/widget_new/missing_value1.rs diff --git a/tests/build/cases/widget_new/missing_value1.stderr b/tests/macro-tests/cases/widget_new/missing_value1.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_value1.stderr rename to tests/macro-tests/cases/widget_new/missing_value1.stderr diff --git a/tests/build/cases/widget_new/missing_value2.rs b/tests/macro-tests/cases/widget_new/missing_value2.rs similarity index 100% rename from tests/build/cases/widget_new/missing_value2.rs rename to tests/macro-tests/cases/widget_new/missing_value2.rs diff --git a/tests/build/cases/widget_new/missing_value2.stderr b/tests/macro-tests/cases/widget_new/missing_value2.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_value2.stderr rename to tests/macro-tests/cases/widget_new/missing_value2.stderr diff --git a/tests/build/cases/widget_new/missing_value3.rs b/tests/macro-tests/cases/widget_new/missing_value3.rs similarity index 100% rename from tests/build/cases/widget_new/missing_value3.rs rename to tests/macro-tests/cases/widget_new/missing_value3.rs diff --git a/tests/build/cases/widget_new/missing_value3.stderr b/tests/macro-tests/cases/widget_new/missing_value3.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_value3.stderr rename to tests/macro-tests/cases/widget_new/missing_value3.stderr diff --git a/tests/build/cases/widget_new/missing_value4.rs b/tests/macro-tests/cases/widget_new/missing_value4.rs similarity index 100% rename from tests/build/cases/widget_new/missing_value4.rs rename to tests/macro-tests/cases/widget_new/missing_value4.rs diff --git a/tests/build/cases/widget_new/missing_value4.stderr b/tests/macro-tests/cases/widget_new/missing_value4.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_value4.stderr rename to tests/macro-tests/cases/widget_new/missing_value4.stderr diff --git a/tests/build/cases/widget_new/missing_value5.rs b/tests/macro-tests/cases/widget_new/missing_value5.rs similarity index 100% rename from tests/build/cases/widget_new/missing_value5.rs rename to tests/macro-tests/cases/widget_new/missing_value5.rs diff --git a/tests/build/cases/widget_new/missing_value5.stderr b/tests/macro-tests/cases/widget_new/missing_value5.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_value5.stderr rename to tests/macro-tests/cases/widget_new/missing_value5.stderr diff --git a/tests/build/cases/widget_new/missing_value6.rs b/tests/macro-tests/cases/widget_new/missing_value6.rs similarity index 100% rename from tests/build/cases/widget_new/missing_value6.rs rename to tests/macro-tests/cases/widget_new/missing_value6.rs diff --git a/tests/build/cases/widget_new/missing_value6.stderr b/tests/macro-tests/cases/widget_new/missing_value6.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_value6.stderr rename to tests/macro-tests/cases/widget_new/missing_value6.stderr diff --git a/tests/build/cases/widget_new/missing_value_before_when1.rs b/tests/macro-tests/cases/widget_new/missing_value_before_when1.rs similarity index 100% rename from tests/build/cases/widget_new/missing_value_before_when1.rs rename to tests/macro-tests/cases/widget_new/missing_value_before_when1.rs diff --git a/tests/build/cases/widget_new/missing_value_before_when1.stderr b/tests/macro-tests/cases/widget_new/missing_value_before_when1.stderr similarity index 100% rename from tests/build/cases/widget_new/missing_value_before_when1.stderr rename to tests/macro-tests/cases/widget_new/missing_value_before_when1.stderr diff --git a/tests/build/cases/widget_new/not_allowed_in_when1.rs b/tests/macro-tests/cases/widget_new/not_allowed_in_when1.rs similarity index 100% rename from tests/build/cases/widget_new/not_allowed_in_when1.rs rename to tests/macro-tests/cases/widget_new/not_allowed_in_when1.rs diff --git a/tests/build/cases/widget_new/not_allowed_in_when1.stderr b/tests/macro-tests/cases/widget_new/not_allowed_in_when1.stderr similarity index 100% rename from tests/build/cases/widget_new/not_allowed_in_when1.stderr rename to tests/macro-tests/cases/widget_new/not_allowed_in_when1.stderr diff --git a/tests/build/cases/widget_new/not_allowed_in_when2.rs b/tests/macro-tests/cases/widget_new/not_allowed_in_when2.rs similarity index 100% rename from tests/build/cases/widget_new/not_allowed_in_when2.rs rename to tests/macro-tests/cases/widget_new/not_allowed_in_when2.rs diff --git a/tests/build/cases/widget_new/not_allowed_in_when2.stderr b/tests/macro-tests/cases/widget_new/not_allowed_in_when2.stderr similarity index 100% rename from tests/build/cases/widget_new/not_allowed_in_when2.stderr rename to tests/macro-tests/cases/widget_new/not_allowed_in_when2.stderr diff --git a/tests/build/cases/widget_new/property_generic1.rs b/tests/macro-tests/cases/widget_new/property_generic1.rs similarity index 100% rename from tests/build/cases/widget_new/property_generic1.rs rename to tests/macro-tests/cases/widget_new/property_generic1.rs diff --git a/tests/build/cases/widget_new/property_generic1.stderr b/tests/macro-tests/cases/widget_new/property_generic1.stderr similarity index 100% rename from tests/build/cases/widget_new/property_generic1.stderr rename to tests/macro-tests/cases/widget_new/property_generic1.stderr diff --git a/tests/build/cases/widget_new/property_generic2.rs b/tests/macro-tests/cases/widget_new/property_generic2.rs similarity index 100% rename from tests/build/cases/widget_new/property_generic2.rs rename to tests/macro-tests/cases/widget_new/property_generic2.rs diff --git a/tests/build/cases/widget_new/property_generic2.stderr b/tests/macro-tests/cases/widget_new/property_generic2.stderr similarity index 100% rename from tests/build/cases/widget_new/property_generic2.stderr rename to tests/macro-tests/cases/widget_new/property_generic2.stderr diff --git a/tests/build/cases/widget_new/unknown_field.rs b/tests/macro-tests/cases/widget_new/unknown_field.rs similarity index 100% rename from tests/build/cases/widget_new/unknown_field.rs rename to tests/macro-tests/cases/widget_new/unknown_field.rs diff --git a/tests/build/cases/widget_new/unknown_field.stderr b/tests/macro-tests/cases/widget_new/unknown_field.stderr similarity index 100% rename from tests/build/cases/widget_new/unknown_field.stderr rename to tests/macro-tests/cases/widget_new/unknown_field.stderr diff --git a/tests/build/cases/widget_new/unknown_member_in_when_expr1.rs b/tests/macro-tests/cases/widget_new/unknown_member_in_when_expr1.rs similarity index 100% rename from tests/build/cases/widget_new/unknown_member_in_when_expr1.rs rename to tests/macro-tests/cases/widget_new/unknown_member_in_when_expr1.rs diff --git a/tests/build/cases/widget_new/unknown_member_in_when_expr1.stderr b/tests/macro-tests/cases/widget_new/unknown_member_in_when_expr1.stderr similarity index 100% rename from tests/build/cases/widget_new/unknown_member_in_when_expr1.stderr rename to tests/macro-tests/cases/widget_new/unknown_member_in_when_expr1.stderr diff --git a/tests/build/cases/widget_new/unknown_member_in_when_expr2.rs b/tests/macro-tests/cases/widget_new/unknown_member_in_when_expr2.rs similarity index 100% rename from tests/build/cases/widget_new/unknown_member_in_when_expr2.rs rename to tests/macro-tests/cases/widget_new/unknown_member_in_when_expr2.rs diff --git a/tests/build/cases/widget_new/unknown_member_in_when_expr2.stderr b/tests/macro-tests/cases/widget_new/unknown_member_in_when_expr2.stderr similarity index 100% rename from tests/build/cases/widget_new/unknown_member_in_when_expr2.stderr rename to tests/macro-tests/cases/widget_new/unknown_member_in_when_expr2.stderr diff --git a/tests/build/cases/widget_new/unknown_property1.rs b/tests/macro-tests/cases/widget_new/unknown_property1.rs similarity index 100% rename from tests/build/cases/widget_new/unknown_property1.rs rename to tests/macro-tests/cases/widget_new/unknown_property1.rs diff --git a/tests/build/cases/widget_new/unknown_property1.stderr b/tests/macro-tests/cases/widget_new/unknown_property1.stderr similarity index 100% rename from tests/build/cases/widget_new/unknown_property1.stderr rename to tests/macro-tests/cases/widget_new/unknown_property1.stderr diff --git a/tests/build/cases/widget_new/unknown_property2.rs b/tests/macro-tests/cases/widget_new/unknown_property2.rs similarity index 100% rename from tests/build/cases/widget_new/unknown_property2.rs rename to tests/macro-tests/cases/widget_new/unknown_property2.rs diff --git a/tests/build/cases/widget_new/unknown_property2.stderr b/tests/macro-tests/cases/widget_new/unknown_property2.stderr similarity index 100% rename from tests/build/cases/widget_new/unknown_property2.stderr rename to tests/macro-tests/cases/widget_new/unknown_property2.stderr diff --git a/tests/build/cases/widget_new/unknown_special_value.rs b/tests/macro-tests/cases/widget_new/unknown_special_value.rs similarity index 100% rename from tests/build/cases/widget_new/unknown_special_value.rs rename to tests/macro-tests/cases/widget_new/unknown_special_value.rs diff --git a/tests/build/cases/widget_new/unknown_special_value.stderr b/tests/macro-tests/cases/widget_new/unknown_special_value.stderr similarity index 100% rename from tests/build/cases/widget_new/unknown_special_value.stderr rename to tests/macro-tests/cases/widget_new/unknown_special_value.stderr diff --git a/tests/build/cases/widget_new/unknown_special_value_in_when.rs b/tests/macro-tests/cases/widget_new/unknown_special_value_in_when.rs similarity index 100% rename from tests/build/cases/widget_new/unknown_special_value_in_when.rs rename to tests/macro-tests/cases/widget_new/unknown_special_value_in_when.rs diff --git a/tests/build/cases/widget_new/unknown_special_value_in_when.stderr b/tests/macro-tests/cases/widget_new/unknown_special_value_in_when.stderr similarity index 100% rename from tests/build/cases/widget_new/unknown_special_value_in_when.stderr rename to tests/macro-tests/cases/widget_new/unknown_special_value_in_when.stderr diff --git a/tests/build/cases/widget_new/when_missing_block.rs b/tests/macro-tests/cases/widget_new/when_missing_block.rs similarity index 100% rename from tests/build/cases/widget_new/when_missing_block.rs rename to tests/macro-tests/cases/widget_new/when_missing_block.rs diff --git a/tests/build/cases/widget_new/when_missing_block.stderr b/tests/macro-tests/cases/widget_new/when_missing_block.stderr similarity index 100% rename from tests/build/cases/widget_new/when_missing_block.stderr rename to tests/macro-tests/cases/widget_new/when_missing_block.stderr diff --git a/tests/build/cases/widget_new/when_missing_expr1.rs b/tests/macro-tests/cases/widget_new/when_missing_expr1.rs similarity index 100% rename from tests/build/cases/widget_new/when_missing_expr1.rs rename to tests/macro-tests/cases/widget_new/when_missing_expr1.rs diff --git a/tests/build/cases/widget_new/when_missing_expr1.stderr b/tests/macro-tests/cases/widget_new/when_missing_expr1.stderr similarity index 100% rename from tests/build/cases/widget_new/when_missing_expr1.stderr rename to tests/macro-tests/cases/widget_new/when_missing_expr1.stderr diff --git a/tests/macro-tests/main.rs b/tests/macro-tests/main.rs new file mode 100644 index 000000000..d759a7fcd --- /dev/null +++ b/tests/macro-tests/main.rs @@ -0,0 +1,9 @@ +//! Use `cargo do test -m --all` to run all macro tests. +//! +//! Use `cargo do test -m property/*` to run all paths that match in the `./cases` folder. + +mod run; + +fn main() { + run::do_request(); +} diff --git a/tests/build/run.rs b/tests/macro-tests/run.rs similarity index 94% rename from tests/build/run.rs rename to tests/macro-tests/run.rs index 990abf872..e1b4b5341 100644 --- a/tests/build/run.rs +++ b/tests/macro-tests/run.rs @@ -1,7 +1,7 @@ use std::{fs, io}; pub fn do_request() { - if let Some(test) = std::env::var_os("DO_TASKS_TEST_BUILD") { + if let Some(test) = std::env::var_os("DO_TASKS_TEST_MACRO") { let mut test = test.to_string_lossy(); if ["*", "**"].contains(&test.as_ref()) { @@ -18,7 +18,7 @@ pub fn do_request() { cleanup(&test); } else { - eprintln!("run with `cargo do test --build *`"); + eprintln!("run with `cargo do test --macro --all`"); } } diff --git a/tools/do-tasks/src/main.rs b/tools/do-tasks/src/main.rs index 73864a4d5..ee9f5471c 100644 --- a/tools/do-tasks/src/main.rs +++ b/tools/do-tasks/src/main.rs @@ -210,10 +210,10 @@ fn doc(mut args: Vec<&str>) { // do test, t [-u, --unit ] // [-t, --test ] -// [-b, --build ] +// [-m, --macro ] // // -// Run all tests in root workspace and build tests. +// Run all tests in root workspace and macro tests. // USAGE: // test -u test::path::function // Run tests that partially match the Rust item path. @@ -223,14 +223,14 @@ fn doc(mut args: Vec<&str>) { // Run all integration tests in the named test. // test -t --all // Run all integration tests. -// test -b property/* -// Run build tests that match the file pattern in `tests/build/cases/`. -// test -b --all -// Run all build tests. +// test -m property/* +// Run macro tests that match the file pattern in `tests/macro-tests/cases/`. +// test -m --all +// Run all macro tests. // test --doc // Run doc tests. // test -// Run all unit, doc, integration and build tests. +// Run all unit, doc, integration and macro tests. fn test(mut args: Vec<&str>) { let nightly = if take_flag(&mut args, &["+nightly"]) { "+nightly" } else { "" }; let env = &[("RUST_BACKTRACE", "full")]; @@ -269,11 +269,11 @@ fn test(mut args: Vec<&str>) { } cmd_env("cargo", &t_args, &args, env); - } else if take_flag(&mut args, &["-b", "--build"]) { - // build tests: + } else if take_flag(&mut args, &["-m", "--macro"]) { + // macro tests: if args.len() != 1 { - error("expected pattern, use do test -b --all to run all build tests"); + error("expected pattern, use do test -m --all to run all macro tests"); } else { let rust_flags = std::env::var("RUSTFLAGS") .unwrap_or_default() @@ -282,12 +282,12 @@ fn test(mut args: Vec<&str>) { .replace("-Dwarnings", ""); cmd_env( "cargo", - &["run", "--package", "build-tests"], + &["run", "--package", "macro-tests"], &[], &[ ("RUSTFLAGS", rust_flags.as_str()), ( - "DO_TASKS_TEST_BUILD", + "DO_TASKS_TEST_MACRO", if args[0] == "--all" || args[0] == "-a" { "*" } else { args[0] }, ), ], @@ -296,8 +296,8 @@ fn test(mut args: Vec<&str>) { let mut changes = vec![]; for m in util::git_modified() { if let Some(ext) = m.extension() { - if ext == "stderr" && m.starts_with("tests/build/cases") { - error(format!("build test `{}` modified", m.display())); + if ext == "stderr" && m.starts_with("tests/macro-tests/cases") { + error(format!("macro test `{}` modified", m.display())); changes.push(m); } } @@ -306,7 +306,7 @@ fn test(mut args: Vec<&str>) { for m in &changes { util::print_git_diff(&m); } - fatal(format!("{} build tests modified, review and commit", changes.len())); + fatal(format!("{} macro tests modified, review and commit", changes.len())); } } } else if take_flag(&mut args, &["--examples"]) { @@ -335,7 +335,7 @@ fn test(mut args: Vec<&str>) { if all { // if no args we run everything. tests::version_in_sync(); - test(vec!["--build", "--all"]); + test(vec!["--macro", "--all"]); } } } @@ -389,7 +389,7 @@ fn run(mut args: Vec<&str>) { } // do expand [-p ] [] [-r, --raw] [-e, --example ] -// [-b, --build [-p, -pass ] [-f, --fail ]] +// [-m, --macro [-p, -pass ] [-f, --fail ]] // [|] // Run "cargo expand" OR if raw is enabled, runs the unstable "--pretty=expanded" check. // FLAGS: @@ -401,11 +401,11 @@ fn run(mut args: Vec<&str>) { // Prints the example. // expand --raw // Prints the entire main crate, including macro_rules!. -// expand --build -p pass_test_name -// Prints the build test cases that match. +// expand --macro -p pass_test_name +// Prints the macro test cases that match. fn expand(mut args: Vec<&str>) { - if args.iter().any(|&a| a == "-b" || a == "--build") { - // Expand build test, we need to run the test to load the bins + if args.iter().any(|&a| a == "-m" || a == "--macro") { + // Expand macro test, we need to run the test to load the bins // in the trybuild test crate. We also test in nightly because // expand is in nightly. @@ -414,7 +414,7 @@ fn expand(mut args: Vec<&str>) { test(test_args); TaskInfo::set_stdout_dump("dump.rs"); - for (bin_name, path) in build_test_cases() { + for (bin_name, path) in macro_test_cases() { let i = path.find("tests").unwrap_or_default(); println(f!("\n//\n// {}\n//\n", &path[i..])); cmd( @@ -505,7 +505,7 @@ fn expand(mut args: Vec<&str>) { } // do fmt, f [] [-- ] -// Format workspace, build test samples, test-crates and the tasks script. +// Format workspace, macro test samples, test-crates and the tasks script. fn fmt(args: Vec<&str>) { print(" fmt workspace ... "); cmd("cargo", &["fmt"], &args); diff --git a/tools/do-tasks/src/util.rs b/tools/do-tasks/src/util.rs index 0f78bea0e..c04c92cd5 100644 --- a/tools/do-tasks/src/util.rs +++ b/tools/do-tasks/src/util.rs @@ -267,9 +267,9 @@ pub fn examples() -> Vec { } } -// [[bin]] names for build tests last run ("bin-name", "test_file_path"). -pub fn build_test_cases() -> Vec<(String, String)> { - match std::fs::read_to_string("target/tests/build-tests/Cargo.toml") { +// [[bin]] names for macro tests last run ("bin-name", "test_file_path"). +pub fn macro_test_cases() -> Vec<(String, String)> { + match std::fs::read_to_string("target/tests/macro-tests/Cargo.toml") { Ok(file) => { let mut bin_names = vec![]; diff --git a/zng-time/src/lib.rs b/zng-time/src/lib.rs index ff05c6c09..8278c0c24 100644 --- a/zng-time/src/lib.rs +++ b/zng-time/src/lib.rs @@ -36,7 +36,9 @@ impl INSTANT { if let Some(t) = *EPOCH.read() { return t; } - *EPOCH.write().get_or_insert_with(|| Instant::now() - Duration::from_secs(60 * 60 * 24)) + *EPOCH + .write() + .get_or_insert_with(|| Instant::now() - Duration::from_secs(60 * 60 * 24)) } /// Defines how the `now` value updates.