├── .github ├── FUNDING.yml ├── dependabot.yml ├── settings.yml └── workflows │ ├── actionlint.yml │ ├── ci.yml │ ├── dependencies.yml │ ├── get_current_crate_version.sh │ ├── get_py_prerelease_name.sh │ ├── get_wasm_prerelease_name.sh │ ├── is_crate_version_already_uploaded.sh │ ├── is_py_package_version_already_uploaded.sh │ ├── publish-python.yml │ ├── publish-rust.yml │ ├── python_bindings_changed.sh │ └── wasm_pkg_changed.sh ├── .gitignore ├── CODEOWNERS ├── Cargo.lock ├── Cargo.toml ├── LICENSE.txt ├── README.md ├── concept_schemas └── cargo_workspace.graphql ├── demo-hytradboi ├── Cargo.toml ├── README.md ├── example_queries │ ├── actions_in_repos_with_min_10_hn_pts.ron │ ├── crates_io_github_actions.ron │ ├── hackernews_github_projects.ron │ ├── hackernews_github_run_steps.ron │ ├── hackernews_patio11_own_post_comments.ron │ └── repos_with_min_50_hackernews_points.ron ├── query-demo.gif ├── schema.graphql └── src │ ├── actions_parser.rs │ ├── adapter.rs │ ├── main.rs │ ├── pagers.rs │ ├── util.rs │ └── vertex.rs ├── experiments ├── browser_based_querying │ ├── .eslintrc.json │ ├── .gitignore │ ├── .prettierignore │ ├── README.md │ ├── babel.config.js │ ├── example_queries │ │ ├── hackernews │ │ │ ├── comments_for_prior_discussion_of_same_story.example │ │ │ ├── comments_that_link_to_other_stories.example │ │ │ ├── comments_with_two_more_author_replies.example │ │ │ ├── latest_stories_with_min_points_and_submitter_karma.example │ │ │ ├── links_in_user_about_section.example │ │ │ ├── patio11_commenting_on_submissions_of_his_blog_posts.example │ │ │ ├── search_plus_hn_apis.example │ │ │ ├── stories_with_code_blocks_in_comments.example │ │ │ └── top_stories_with_min_points_and_submitter_karma.example │ │ └── rustdoc │ │ │ ├── enums_with_tuple_variants.example │ │ │ ├── items_with_allowed_lints.example │ │ │ ├── iter_structs.example │ │ │ ├── struct_names_and_spans.example │ │ │ ├── structs_and_fields.example │ │ │ ├── structs_importable_by_multiple_paths.example │ │ │ ├── trait_associated_consts.example │ │ │ ├── traits_with_associated_types.example │ │ │ ├── traits_with_supertraits.example │ │ │ └── type_associated_consts.example │ ├── index.d.ts │ ├── package.json │ ├── patches │ │ ├── graphql-language-service@5.2.0.patch │ │ └── monaco-editor@0.44.0.patch │ ├── pnpm-lock.yaml │ ├── prettier.config.js │ ├── server.py │ ├── src │ │ ├── App.tsx │ │ ├── QueryFragmentAdapter.tsx │ │ ├── TrustfallPlayground.tsx │ │ ├── components │ │ │ ├── DocExplorer.tsx │ │ │ ├── DocExplorer │ │ │ │ ├── Argument.tsx │ │ │ │ ├── DefaultValue.tsx │ │ │ │ ├── Directive.tsx │ │ │ │ ├── FieldDoc.tsx │ │ │ │ ├── FieldLink.tsx │ │ │ │ ├── LICENSE │ │ │ │ ├── MarkdownContent.tsx │ │ │ │ ├── SchemaDoc.tsx │ │ │ │ ├── SearchBox.tsx │ │ │ │ ├── SearchResults.tsx │ │ │ │ ├── Styles.tsx │ │ │ │ ├── TypeDoc.tsx │ │ │ │ └── TypeLink.tsx │ │ │ └── SimpleDocExplorer.tsx │ │ ├── hackernews │ │ │ ├── Playground.tsx │ │ │ ├── adapter.ts │ │ │ ├── fetcher.ts │ │ │ ├── schema.graphql │ │ │ └── utils.ts │ │ ├── index.ejs │ │ ├── index.tsx │ │ ├── rustdoc │ │ │ ├── Playground.tsx │ │ │ ├── queryWorker.ts │ │ │ └── types.ts │ │ ├── rustdocCrates.ts │ │ ├── sync.ts │ │ ├── testIndex.ts │ │ ├── types.ts │ │ ├── urlCompression.ts │ │ └── utils │ │ │ ├── debug.ts │ │ │ └── parseExample.ts │ ├── tsconfig.json │ └── webpack.config.js ├── schemaless │ ├── Cargo.toml │ ├── example_queries │ │ ├── actions_in_repos_with_min_hn_pts.graphql │ │ ├── crates_io_github_actions.graphql │ │ ├── hackernews_github_projects.graphql │ │ ├── hackernews_github_run_steps.graphql │ │ ├── hackernews_patio11_own_post_comments.graphql │ │ └── repos_with_min_hackernews_points.graphql │ └── src │ │ ├── lib.rs │ │ ├── main.rs │ │ └── schema_inference.rs ├── schemaless_wasm │ ├── Cargo.toml │ ├── src │ │ ├── lib.rs │ │ └── util.rs │ └── www │ │ ├── .eslintrc.json │ │ ├── .gitignore │ │ ├── babel.config.js │ │ ├── package-lock.json │ │ ├── package.json │ │ ├── prettier.config.js │ │ ├── src │ │ ├── App.tsx │ │ ├── bootstrap.ts │ │ ├── exampleQueries.ts │ │ ├── index.ejs │ │ └── index.tsx │ │ ├── tsconfig.json │ │ └── webpack.config.js └── trustfall_rustdoc │ ├── Cargo.lock │ ├── Cargo.toml │ ├── README.md │ ├── src │ ├── lib.rs │ ├── rustdoc_schema.graphql │ └── trustfall_rustdoc.d.ts │ └── tests │ ├── test_crate_info.json │ └── web.rs ├── pytrustfall ├── Cargo.toml ├── README.md ├── demo.ipynb ├── numbers.graphql ├── poetry.lock ├── pyproject.toml ├── src │ ├── errors.rs │ ├── lib.rs │ ├── shim.rs │ └── value.rs └── trustfall │ ├── __init__.py │ ├── _internals.py │ ├── _internals.pyi │ ├── adapter.py │ ├── execution.py │ ├── py.typed │ └── tests │ ├── __init__.py │ ├── numbers_adapter.py │ ├── test_execution.py │ └── test_schema.py ├── rustfmt.toml ├── scripts ├── create_execution_error_data.sh ├── create_frontend_error_data.sh ├── create_graphql_corpus.sh ├── create_parse_error_data.sh ├── create_schema_error_data.sh ├── create_valid_query_data.sh ├── recreate_all_execution_errors.sh ├── recreate_all_frontend_errors.sh ├── recreate_all_ir.sh ├── recreate_all_outputs.sh ├── recreate_all_parse_errors.sh ├── recreate_all_parsed_graphql.sh ├── recreate_all_schema_errors.sh ├── recreate_all_traces.sh └── reserialize_all_test_files.sh ├── spec.md ├── trustfall ├── Cargo.toml ├── LICENSE.txt ├── examples │ ├── README.md │ ├── feeds │ │ ├── README.md │ │ ├── adapter.rs │ │ ├── example_queries │ │ │ ├── feed_content.ron │ │ │ ├── feed_links.ron │ │ │ └── game_reviews.ron │ │ ├── feeds.graphql │ │ ├── main.rs │ │ └── util.rs │ ├── hackernews │ │ ├── README.md │ │ ├── adapter.rs │ │ ├── example_queries │ │ │ ├── front_page_stories_with_links.ron │ │ │ ├── highly_rated_stories_by_specific_user.ron │ │ │ ├── jobs_in_top_50.ron │ │ │ ├── latest_links_by_high_karma_users.ron │ │ │ ├── links_with_high_karma_commenters.ron │ │ │ └── patio11_comments_on_own_blog_posts.ron │ │ ├── hackernews.graphql │ │ ├── main.rs │ │ ├── util.rs │ │ └── vertex.rs │ └── weather │ │ ├── README.md │ │ ├── adapter.rs │ │ ├── example_queries │ │ ├── boston_weather.ron │ │ └── high_winds.ron │ │ ├── main.rs │ │ ├── metar.rs │ │ ├── metar_weather.graphql │ │ └── util.rs ├── src │ └── lib.rs └── tests │ └── helper_macros.rs ├── trustfall_core ├── Cargo.toml ├── LICENSE.txt ├── fuzz │ ├── .gitignore │ ├── Cargo.lock │ ├── Cargo.toml │ └── fuzz_targets │ │ ├── adapter_batching │ │ ├── mod.rs │ │ └── numbers_adapter.rs │ │ ├── frontend.rs │ │ └── frontend_numbers.rs ├── src │ ├── filesystem_interpreter.rs │ ├── frontend │ │ ├── error.rs │ │ ├── filters.rs │ │ ├── mod.rs │ │ ├── outputs.rs │ │ ├── tags.rs │ │ ├── util.rs │ │ └── validation.rs │ ├── graphql_query │ │ ├── directives.rs │ │ ├── error.rs │ │ ├── mod.rs │ │ └── query.rs │ ├── interpreter │ │ ├── basic_adapter.rs │ │ ├── error.rs │ │ ├── execution.rs │ │ ├── filtering.rs │ │ ├── helpers │ │ │ ├── correctness.rs │ │ │ ├── mod.rs │ │ │ └── tests.rs │ │ ├── hints │ │ │ ├── candidates.rs │ │ │ ├── dynamic.rs │ │ │ ├── filters.rs │ │ │ ├── mod.rs │ │ │ ├── sealed.rs │ │ │ ├── tests │ │ │ │ └── mod.rs │ │ │ └── vertex_info.rs │ │ ├── mod.rs │ │ ├── replay.rs │ │ └── trace.rs │ ├── ir │ │ ├── indexed.rs │ │ ├── mod.rs │ │ ├── types │ │ │ ├── base.rs │ │ │ ├── mod.rs │ │ │ └── named_typed.rs │ │ └── value.rs │ ├── lib.rs │ ├── nullables_interpreter.rs │ ├── numbers_interpreter.rs │ ├── schema │ │ ├── adapter │ │ │ ├── mod.rs │ │ │ ├── schema.graphql │ │ │ └── tests.rs │ │ ├── error.rs │ │ └── mod.rs │ ├── serialization │ │ ├── deserializers.rs │ │ ├── mod.rs │ │ └── tests.rs │ ├── test_types.rs │ └── util.rs └── test_data │ ├── README.md │ ├── schemas │ ├── filesystem.graphql │ ├── nullables.graphql │ ├── numbers.graphql │ ├── parameterized_edges.graphql │ └── recurses.graphql │ └── tests │ ├── execution_errors │ ├── both_missing_and_unused.exec-error.ron │ ├── both_missing_and_unused.graphql-parsed.ron │ ├── both_missing_and_unused.graphql.ron │ ├── both_missing_and_unused.ir.ron │ ├── invalid_argument_types.exec-error.ron │ ├── invalid_argument_types.graphql-parsed.ron │ ├── invalid_argument_types.graphql.ron │ ├── invalid_argument_types.ir.ron │ ├── invalid_null_argument_values.exec-error.ron │ ├── invalid_null_argument_values.graphql-parsed.ron │ ├── invalid_null_argument_values.graphql.ron │ ├── invalid_null_argument_values.ir.ron │ ├── missing_argument.exec-error.ron │ ├── missing_argument.graphql-parsed.ron │ ├── missing_argument.graphql.ron │ ├── missing_argument.ir.ron │ ├── missing_unused_and_invalid_arguments.exec-error.ron │ ├── missing_unused_and_invalid_arguments.graphql-parsed.ron │ ├── missing_unused_and_invalid_arguments.graphql.ron │ ├── missing_unused_and_invalid_arguments.ir.ron │ ├── type_narrowing_prevents_list_with_null_argument.exec-error.ron │ ├── type_narrowing_prevents_list_with_null_argument.graphql-parsed.ron │ ├── type_narrowing_prevents_list_with_null_argument.graphql.ron │ ├── type_narrowing_prevents_list_with_null_argument.ir.ron │ ├── type_narrowing_prevents_null_argument.exec-error.ron │ ├── type_narrowing_prevents_null_argument.graphql-parsed.ron │ ├── type_narrowing_prevents_null_argument.graphql.ron │ ├── type_narrowing_prevents_null_argument.ir.ron │ ├── unused_argument.exec-error.ron │ ├── unused_argument.graphql-parsed.ron │ ├── unused_argument.graphql.ron │ └── unused_argument.ir.ron │ ├── frontend_errors │ ├── coercion_of_non_interface.frontend-error.ron │ ├── coercion_of_non_interface.graphql-parsed.ron │ ├── coercion_of_non_interface.graphql.ron │ ├── coercion_to_nonexistent_type.frontend-error.ron │ ├── coercion_to_nonexistent_type.graphql-parsed.ron │ ├── coercion_to_nonexistent_type.graphql.ron │ ├── coercion_to_unrelated_type.frontend-error.ron │ ├── coercion_to_unrelated_type.graphql-parsed.ron │ ├── coercion_to_unrelated_type.graphql.ron │ ├── duplicate_field_with_output.frontend-error.ron │ ├── duplicate_field_with_output.graphql-parsed.ron │ ├── duplicate_field_with_output.graphql.ron │ ├── duplicate_output.frontend-error.ron │ ├── duplicate_output.graphql-parsed.ron │ ├── duplicate_output.graphql.ron │ ├── duplicate_output_from_different_vertices.frontend-error.ron │ ├── duplicate_output_from_different_vertices.graphql-parsed.ron │ ├── duplicate_output_from_different_vertices.graphql.ron │ ├── duplicate_output_from_parallel_components.frontend-error.ron │ ├── duplicate_output_from_parallel_components.graphql-parsed.ron │ ├── duplicate_output_from_parallel_components.graphql.ron │ ├── duplicate_output_from_prefix.frontend-error.ron │ ├── duplicate_output_from_prefix.graphql-parsed.ron │ ├── duplicate_output_from_prefix.graphql.ron │ ├── duplicate_output_from_subcomponent.frontend-error.ron │ ├── duplicate_output_from_subcomponent.graphql-parsed.ron │ ├── duplicate_output_from_subcomponent.graphql.ron │ ├── duplicate_output_implicit_and_explicit_fold_count_name.frontend-error.ron │ ├── duplicate_output_implicit_and_explicit_fold_count_name.graphql-parsed.ron │ ├── duplicate_output_implicit_and_explicit_fold_count_name.graphql.ron │ ├── duplicate_output_implicit_fold_count_names.frontend-error.ron │ ├── duplicate_output_implicit_fold_count_names.graphql-parsed.ron │ ├── duplicate_output_implicit_fold_count_names.graphql.ron │ ├── duplicate_tag.frontend-error.ron │ ├── duplicate_tag.graphql-parsed.ron │ ├── duplicate_tag.graphql.ron │ ├── duplicate_tag_across_fold.frontend-error.ron │ ├── duplicate_tag_across_fold.graphql-parsed.ron │ ├── duplicate_tag_across_fold.graphql.ron │ ├── duplicate_tag_in_nested_fold.frontend-error.ron │ ├── duplicate_tag_in_nested_fold.graphql-parsed.ron │ ├── duplicate_tag_in_nested_fold.graphql.ron │ ├── duplicate_tag_in_separate_folds.frontend-error.ron │ ├── duplicate_tag_in_separate_folds.graphql-parsed.ron │ ├── duplicate_tag_in_separate_folds.graphql.ron │ ├── duplicate_tag_with_parent_after_fold.frontend-error.ron │ ├── duplicate_tag_with_parent_after_fold.graphql-parsed.ron │ ├── duplicate_tag_with_parent_after_fold.graphql.ron │ ├── explicit_null_in_non_nullable_edge_parameter.frontend-error.ron │ ├── explicit_null_in_non_nullable_edge_parameter.graphql-parsed.ron │ ├── explicit_null_in_non_nullable_edge_parameter.graphql.ron │ ├── filter_contains_on_non_container.frontend-error.ron │ ├── filter_contains_on_non_container.graphql-parsed.ron │ ├── filter_contains_on_non_container.graphql.ron │ ├── filter_contains_with_uncontainable_type.frontend-error.ron │ ├── filter_contains_with_uncontainable_type.graphql-parsed.ron │ ├── filter_contains_with_uncontainable_type.graphql.ron │ ├── filter_directive_on_edge.frontend-error.ron │ ├── filter_directive_on_edge.graphql-parsed.ron │ ├── filter_directive_on_edge.graphql.ron │ ├── filter_directive_on_edge_bare.frontend-error.ron │ ├── filter_directive_on_edge_bare.graphql-parsed.ron │ ├── filter_directive_on_edge_bare.graphql.ron │ ├── filter_non_null_field_for_null.frontend-error.ron │ ├── filter_non_null_field_for_null.graphql-parsed.ron │ ├── filter_non_null_field_for_null.graphql.ron │ ├── filter_non_nullable_field_for_non_null.frontend-error.ron │ ├── filter_non_nullable_field_for_non_null.graphql-parsed.ron │ ├── filter_non_nullable_field_for_non_null.graphql.ron │ ├── filter_non_orderable_types.frontend-error.ron │ ├── filter_non_orderable_types.graphql-parsed.ron │ ├── filter_non_orderable_types.graphql.ron │ ├── filter_one_of_on_uncontainable_type.frontend-error.ron │ ├── filter_one_of_on_uncontainable_type.graphql-parsed.ron │ ├── filter_one_of_on_uncontainable_type.graphql.ron │ ├── filter_one_of_with_non_container_type.frontend-error.ron │ ├── filter_one_of_with_non_container_type.graphql-parsed.ron │ ├── filter_one_of_with_non_container_type.graphql.ron │ ├── filter_orderable_type_mismatch.frontend-error.ron │ ├── filter_orderable_type_mismatch.graphql-parsed.ron │ ├── filter_orderable_type_mismatch.graphql.ron │ ├── filter_regex_on_non_strings.frontend-error.ron │ ├── filter_regex_on_non_strings.graphql-parsed.ron │ ├── filter_regex_on_non_strings.graphql.ron │ ├── filter_tag_type_mismatch_both_non_nullable.frontend-error.ron │ ├── filter_tag_type_mismatch_both_non_nullable.graphql-parsed.ron │ ├── filter_tag_type_mismatch_both_non_nullable.graphql.ron │ ├── filter_tag_type_mismatch_both_nullable.frontend-error.ron │ ├── filter_tag_type_mismatch_both_nullable.graphql-parsed.ron │ ├── filter_tag_type_mismatch_both_nullable.graphql.ron │ ├── filter_tag_type_mismatch_field_non_nullable.frontend-error.ron │ ├── filter_tag_type_mismatch_field_non_nullable.graphql-parsed.ron │ ├── filter_tag_type_mismatch_field_non_nullable.graphql.ron │ ├── filter_tag_type_mismatch_tag_non_nullable.frontend-error.ron │ ├── filter_tag_type_mismatch_tag_non_nullable.graphql-parsed.ron │ ├── filter_tag_type_mismatch_tag_non_nullable.graphql.ron │ ├── fold_and_transform_used_on_property.frontend-error.ron │ ├── fold_and_transform_used_on_property.graphql-parsed.ron │ ├── fold_and_transform_used_on_property.graphql.ron │ ├── fold_count_tag_value_used_inside_own_fold.frontend-error.ron │ ├── fold_count_tag_value_used_inside_own_fold.graphql-parsed.ron │ ├── fold_count_tag_value_used_inside_own_fold.graphql.ron │ ├── fold_used_on_property.frontend-error.ron │ ├── fold_used_on_property.graphql-parsed.ron │ ├── fold_used_on_property.graphql.ron │ ├── implicit_tag_name_on_transformed_value.frontend-error.ron │ ├── implicit_tag_name_on_transformed_value.graphql-parsed.ron │ ├── implicit_tag_name_on_transformed_value.graphql.ron │ ├── incompatible_list_inferred_variable_types.frontend-error.ron │ ├── incompatible_list_inferred_variable_types.graphql-parsed.ron │ ├── incompatible_list_inferred_variable_types.graphql.ron │ ├── incompatible_list_vs_nested_list_variable_types.frontend-error.ron │ ├── incompatible_list_vs_nested_list_variable_types.graphql-parsed.ron │ ├── incompatible_list_vs_nested_list_variable_types.graphql.ron │ ├── incompatible_scalar_inferred_variable_types.frontend-error.ron │ ├── incompatible_scalar_inferred_variable_types.graphql-parsed.ron │ ├── incompatible_scalar_inferred_variable_types.graphql.ron │ ├── incompatible_scalar_vs_list_inferred_variable_types.frontend-error.ron │ ├── incompatible_scalar_vs_list_inferred_variable_types.graphql-parsed.ron │ ├── incompatible_scalar_vs_list_inferred_variable_types.graphql.ron │ ├── incorrect_edge_parameter_type.frontend-error.ron │ ├── incorrect_edge_parameter_type.graphql-parsed.ron │ ├── incorrect_edge_parameter_type.graphql.ron │ ├── missing_multiple_required_edge_parameters.frontend-error.ron │ ├── missing_multiple_required_edge_parameters.graphql-parsed.ron │ ├── missing_multiple_required_edge_parameters.graphql.ron │ ├── missing_required_edge_parameter.frontend-error.ron │ ├── missing_required_edge_parameter.graphql-parsed.ron │ ├── missing_required_edge_parameter.graphql.ron │ ├── multiple_fold_output_errors.frontend-error.ron │ ├── multiple_fold_output_errors.graphql-parsed.ron │ ├── multiple_fold_output_errors.graphql.ron │ ├── non_existent_bare_root.frontend-error.ron │ ├── non_existent_bare_root.graphql-parsed.ron │ ├── non_existent_bare_root.graphql.ron │ ├── non_existent_child.frontend-error.ron │ ├── non_existent_child.graphql-parsed.ron │ ├── non_existent_child.graphql.ron │ ├── non_existent_expanded_root.frontend-error.ron │ ├── non_existent_expanded_root.graphql-parsed.ron │ ├── non_existent_expanded_root.graphql.ron │ ├── optional_and_fold.frontend-error.ron │ ├── optional_and_fold.graphql-parsed.ron │ ├── optional_and_fold.graphql.ron │ ├── optional_used_on_property.frontend-error.ron │ ├── optional_used_on_property.graphql-parsed.ron │ ├── optional_used_on_property.graphql.ron │ ├── output_directive_on_edge.frontend-error.ron │ ├── output_directive_on_edge.graphql-parsed.ron │ ├── output_directive_on_edge.graphql.ron │ ├── output_directive_on_edge_bare.frontend-error.ron │ ├── output_directive_on_edge_bare.graphql-parsed.ron │ ├── output_directive_on_edge_bare.graphql.ron │ ├── recurse_and_fold.frontend-error.ron │ ├── recurse_and_fold.graphql-parsed.ron │ ├── recurse_and_fold.graphql.ron │ ├── recurse_on_same_name_edge_of_unrelated_type.frontend-error.ron │ ├── recurse_on_same_name_edge_of_unrelated_type.graphql-parsed.ron │ ├── recurse_on_same_name_edge_of_unrelated_type.graphql.ron │ ├── recurse_used_on_property.frontend-error.ron │ ├── recurse_used_on_property.graphql-parsed.ron │ ├── recurse_used_on_property.graphql.ron │ ├── recursion_needing_multiple_implicit_coercions.frontend-error.ron │ ├── recursion_needing_multiple_implicit_coercions.graphql-parsed.ron │ ├── recursion_needing_multiple_implicit_coercions.graphql.ron │ ├── recursion_needing_multiple_implicit_coercions_based_on_origin.frontend-error.ron │ ├── recursion_needing_multiple_implicit_coercions_based_on_origin.graphql-parsed.ron │ ├── recursion_needing_multiple_implicit_coercions_based_on_origin.graphql.ron │ ├── recursion_on_non_recursable_edge.frontend-error.ron │ ├── recursion_on_non_recursable_edge.graphql-parsed.ron │ ├── recursion_on_non_recursable_edge.graphql.ron │ ├── recursion_to_subtype.frontend-error.ron │ ├── recursion_to_subtype.graphql-parsed.ron │ ├── recursion_to_subtype.graphql.ron │ ├── tag_and_filter_in_unrelated_folds.frontend-error.ron │ ├── tag_and_filter_in_unrelated_folds.graphql-parsed.ron │ ├── tag_and_filter_in_unrelated_folds.graphql.ron │ ├── tag_before_filter_in_different_scopes.frontend-error.ron │ ├── tag_before_filter_in_different_scopes.graphql-parsed.ron │ ├── tag_before_filter_in_different_scopes.graphql.ron │ ├── tag_from_inside_fold.frontend-error.ron │ ├── tag_from_inside_fold.graphql-parsed.ron │ ├── tag_from_inside_fold.graphql.ron │ ├── tag_on_an_edge.frontend-error.ron │ ├── tag_on_an_edge.graphql-parsed.ron │ ├── tag_on_an_edge.graphql.ron │ ├── tag_used_in_fold_but_defined_after.frontend-error.ron │ ├── tag_used_in_fold_but_defined_after.graphql-parsed.ron │ ├── tag_used_in_fold_but_defined_after.graphql.ron │ ├── typename_as_edge.frontend-error.ron │ ├── typename_as_edge.graphql-parsed.ron │ ├── typename_as_edge.graphql.ron │ ├── typename_is_not_null.frontend-error.ron │ ├── typename_is_not_null.graphql-parsed.ron │ ├── typename_is_not_null.graphql.ron │ ├── undefined_tag.frontend-error.ron │ ├── undefined_tag.graphql-parsed.ron │ ├── undefined_tag.graphql.ron │ ├── unexpected_edge_parameters.frontend-error.ron │ ├── unexpected_edge_parameters.graphql-parsed.ron │ ├── unexpected_edge_parameters.graphql.ron │ ├── unused_tag.frontend-error.ron │ ├── unused_tag.graphql-parsed.ron │ └── unused_tag.graphql.ron │ ├── parse_errors │ ├── coercion_with_sibling_fields.graphql.ron │ ├── coercion_with_sibling_fields.parse-error.ron │ ├── directive_before_root.graphql.ron │ ├── directive_before_root.parse-error.ron │ ├── directive_on_root.graphql.ron │ ├── directive_on_root.parse-error.ron │ ├── duplicate_edge_parameter.graphql.ron │ ├── duplicate_edge_parameter.parse-error.ron │ ├── duplicate_fold.graphql.ron │ ├── duplicate_fold.parse-error.ron │ ├── duplicate_optional.graphql.ron │ ├── duplicate_optional.parse-error.ron │ ├── duplicate_recurse.graphql.ron │ ├── duplicate_recurse.parse-error.ron │ ├── filter_with_tag_string_instead_of_array_with_tag_string.graphql.ron │ ├── filter_with_tag_string_instead_of_array_with_tag_string.parse-error.ron │ ├── filter_with_value_of_just_dollar_sign.graphql.ron │ ├── filter_with_value_of_just_dollar_sign.parse-error.ron │ ├── filter_with_value_of_just_percent_sign.graphql.ron │ ├── filter_with_value_of_just_percent_sign.parse-error.ron │ ├── filter_with_variable_string_instead_of_array_with_variable_string.graphql.ron │ ├── filter_with_variable_string_instead_of_array_with_variable_string.parse-error.ron │ ├── fold_and_optional.graphql.ron │ ├── fold_and_optional.parse-error.ron │ ├── fold_and_output.graphql.ron │ ├── fold_and_output.parse-error.ron │ ├── fold_and_recurse.graphql.ron │ ├── fold_and_recurse.parse-error.ron │ ├── fragment_spread.graphql.ron │ ├── fragment_spread.parse-error.ron │ ├── invalid_edge_argument.graphql.ron │ ├── invalid_edge_argument.parse-error.ron │ ├── invalid_filter_argument_name.graphql.ron │ ├── invalid_filter_argument_name.parse-error.ron │ ├── invalid_filter_argument_name_start.graphql.ron │ ├── invalid_filter_argument_name_start.parse-error.ron │ ├── invalid_filter_op.graphql.ron │ ├── invalid_filter_op.parse-error.ron │ ├── invalid_fold_transform_op.graphql.ron │ ├── invalid_fold_transform_op.parse-error.ron │ ├── multiple_roots.graphql.ron │ ├── multiple_roots.parse-error.ron │ ├── nested_type_coercion.graphql.ron │ ├── nested_type_coercion.parse-error.ron │ ├── output_name_with_dashes.graphql.ron │ ├── output_name_with_dashes.parse-error.ron │ ├── output_name_with_multiple_invalid_chars.graphql.ron │ ├── output_name_with_multiple_invalid_chars.parse-error.ron │ ├── output_name_with_spaces.graphql.ron │ ├── output_name_with_spaces.parse-error.ron │ ├── tag_name_with_multiple_invalid_chars.graphql.ron │ ├── tag_name_with_multiple_invalid_chars.parse-error.ron │ ├── tag_on_fold.graphql.ron │ ├── tag_on_fold.parse-error.ron │ ├── transform_first_directive.graphql.ron │ ├── transform_first_directive.parse-error.ron │ ├── typo_in_filter_value_argument_name.graphql.ron │ ├── typo_in_filter_value_argument_name.parse-error.ron │ ├── unrecognized_directive.graphql.ron │ ├── unrecognized_directive.parse-error.ron │ ├── variable_in_root_query.graphql.ron │ └── variable_in_root_query.parse-error.ron │ ├── schema_errors │ ├── ambiguous_field_origin.graphql │ ├── ambiguous_field_origin.schema-error.ron │ ├── circular_implements_relationship.graphql │ ├── circular_implements_relationship.schema-error.ron │ ├── completely_different_field_type.graphql │ ├── completely_different_field_type.schema-error.ron │ ├── edge_to_root_query_type.graphql │ ├── edge_to_root_query_type.schema-error.ron │ ├── explicit_null_default_for_non_nullable_edge_param.graphql │ ├── explicit_null_default_for_non_nullable_edge_param.schema-error.ron │ ├── implementing_non_existent_type.graphql │ ├── implementing_non_existent_type.schema-error.ron │ ├── implementing_object_type.graphql │ ├── implementing_object_type.schema-error.ron │ ├── implementing_self_type.graphql │ ├── implementing_self_type.schema-error.ron │ ├── incorrect_default_value_type_for_edge_param.graphql │ ├── incorrect_default_value_type_for_edge_param.schema-error.ron │ ├── interface_with_same_field_twice.graphql │ ├── interface_with_same_field_twice.schema-error.ron │ ├── list_of_list_edge.graphql │ ├── list_of_list_edge.schema-error.ron │ ├── list_of_list_root_edge.graphql │ ├── list_of_list_root_edge.schema-error.ron │ ├── missing_field_and_illegal_type_widening.graphql │ ├── missing_field_and_illegal_type_widening.schema-error.ron │ ├── missing_required_field.graphql │ ├── missing_required_field.schema-error.ron │ ├── one_type_one_interface_both_same_name.graphql │ ├── one_type_one_interface_both_same_name.schema-error.ron │ ├── parameterized_field_missing_parameter_in_subtype.graphql │ ├── parameterized_field_missing_parameter_in_subtype.schema-error.ron │ ├── parameters_in_property_field.graphql │ ├── parameters_in_property_field.schema-error.ron │ ├── property_on_root_query_type.graphql │ ├── property_on_root_query_type.schema-error.ron │ ├── reserved_prefix_edge_defined.graphql │ ├── reserved_prefix_edge_defined.schema-error.ron │ ├── reserved_prefix_property_defined.graphql │ ├── reserved_prefix_property_defined.schema-error.ron │ ├── reserved_prefix_query_type.graphql │ ├── reserved_prefix_query_type.schema-error.ron │ ├── reserved_prefix_top_level_field.graphql │ ├── reserved_prefix_top_level_field.schema-error.ron │ ├── reserved_prefix_type_name.graphql │ ├── reserved_prefix_type_name.schema-error.ron │ ├── root_edge_to_root_query_type.graphql │ ├── root_edge_to_root_query_type.schema-error.ron │ ├── subtype_adds_parameter_to_field.graphql │ ├── subtype_adds_parameter_to_field.schema-error.ron │ ├── transitive_interface_not_implemented.graphql │ ├── transitive_interface_not_implemented.schema-error.ron │ ├── triple_list_edge.graphql │ ├── triple_list_edge.schema-error.ron │ ├── triple_list_root_edge.graphql │ ├── triple_list_root_edge.schema-error.ron │ ├── two_interface_same_name.graphql │ ├── two_interface_same_name.schema-error.ron │ ├── two_types_same_name.graphql │ ├── two_types_same_name.schema-error.ron │ ├── type_narrowing_parameterized_edge.graphql │ ├── type_narrowing_parameterized_edge.schema-error.ron │ ├── type_narrowing_parameterized_edge_list_param.graphql │ ├── type_narrowing_parameterized_edge_list_param.schema-error.ron │ ├── type_widening_edge_supertype.graphql │ ├── type_widening_edge_supertype.schema-error.ron │ ├── type_widening_list_edge_supertype.graphql │ ├── type_widening_list_edge_supertype.schema-error.ron │ ├── type_widening_nullability_on_edge_field.graphql │ ├── type_widening_nullability_on_edge_field.schema-error.ron │ ├── type_widening_nullability_on_list_edge_field.graphql │ ├── type_widening_nullability_on_list_edge_field.schema-error.ron │ ├── type_widening_of_inherited_list_fields.graphql │ ├── type_widening_of_inherited_list_fields.schema-error.ron │ ├── type_widening_of_inherited_scalar_field.graphql │ ├── type_widening_of_inherited_scalar_field.schema-error.ron │ ├── type_with_same_field_twice.graphql │ ├── type_with_same_field_twice.schema-error.ron │ ├── unknown_type_not_on_root.graphql │ ├── unknown_type_not_on_root.schema-error.ron │ ├── unknown_type_on_root.graphql │ ├── unknown_type_on_root.schema-error.ron │ ├── unknown_type_on_root_and_outside.graphql │ └── unknown_type_on_root_and_outside.schema-error.ron │ ├── valid_queries │ ├── alias_and_prefix_output_names.graphql-parsed.ron │ ├── alias_and_prefix_output_names.graphql.ron │ ├── alias_and_prefix_output_names.ir.ron │ ├── alias_and_prefix_output_names.output.ron │ ├── alias_and_prefix_output_names.trace.ron │ ├── alias_driven_output_names.graphql-parsed.ron │ ├── alias_driven_output_names.graphql.ron │ ├── alias_driven_output_names.ir.ron │ ├── alias_driven_output_names.output.ron │ ├── alias_driven_output_names.trace.ron │ ├── alias_driven_tag_and_output_names.graphql-parsed.ron │ ├── alias_driven_tag_and_output_names.graphql.ron │ ├── alias_driven_tag_and_output_names.ir.ron │ ├── alias_driven_tag_and_output_names.output.ron │ ├── alias_driven_tag_and_output_names.trace.ron │ ├── avoid_output_name_conflict_with_alias_name.graphql-parsed.ron │ ├── avoid_output_name_conflict_with_alias_name.graphql.ron │ ├── avoid_output_name_conflict_with_alias_name.ir.ron │ ├── avoid_output_name_conflict_with_alias_name.output.ron │ ├── avoid_output_name_conflict_with_alias_name.trace.ron │ ├── coercion_allows_additional_edge.graphql-parsed.ron │ ├── coercion_allows_additional_edge.graphql.ron │ ├── coercion_allows_additional_edge.ir.ron │ ├── coercion_allows_additional_edge.output.ron │ ├── coercion_allows_additional_edge.trace.ron │ ├── coercion_on_edge.graphql-parsed.ron │ ├── coercion_on_edge.graphql.ron │ ├── coercion_on_edge.ir.ron │ ├── coercion_on_edge.output.ron │ ├── coercion_on_edge.trace.ron │ ├── coercion_on_folded_edge.graphql-parsed.ron │ ├── coercion_on_folded_edge.graphql.ron │ ├── coercion_on_folded_edge.ir.ron │ ├── coercion_on_folded_edge.output.ron │ ├── coercion_on_folded_edge.trace.ron │ ├── coercion_on_optional_edge.graphql-parsed.ron │ ├── coercion_on_optional_edge.graphql.ron │ ├── coercion_on_optional_edge.ir.ron │ ├── coercion_on_optional_edge.output.ron │ ├── coercion_on_optional_edge.trace.ron │ ├── coercion_on_recursed_edge.graphql-parsed.ron │ ├── coercion_on_recursed_edge.graphql.ron │ ├── coercion_on_recursed_edge.ir.ron │ ├── coercion_on_recursed_edge.output.ron │ ├── coercion_on_recursed_edge.trace.ron │ ├── deep_optional.graphql-parsed.ron │ ├── deep_optional.graphql.ron │ ├── deep_optional.ir.ron │ ├── deep_optional.output.ron │ ├── deep_optional.trace.ron │ ├── duplicated_edge.graphql-parsed.ron │ ├── duplicated_edge.graphql.ron │ ├── duplicated_edge.ir.ron │ ├── duplicated_edge.output.ron │ ├── duplicated_edge.trace.ron │ ├── edge_parameter.graphql-parsed.ron │ ├── edge_parameter.graphql.ron │ ├── edge_parameter.ir.ron │ ├── edge_parameter.output.ron │ ├── edge_parameter.trace.ron │ ├── edge_parameters_on_non_root.graphql-parsed.ron │ ├── edge_parameters_on_non_root.graphql.ron │ ├── edge_parameters_on_non_root.ir.ron │ ├── edge_parameters_on_non_root.output.ron │ ├── edge_parameters_on_non_root.trace.ron │ ├── empty_fold_output.graphql-parsed.ron │ ├── empty_fold_output.graphql.ron │ ├── empty_fold_output.ir.ron │ ├── empty_fold_output.output.ron │ ├── empty_fold_output.trace.ron │ ├── execute_fold_before_traverse.graphql-parsed.ron │ ├── execute_fold_before_traverse.graphql.ron │ ├── execute_fold_before_traverse.ir.ron │ ├── execute_fold_before_traverse.output.ron │ ├── execute_fold_before_traverse.trace.ron │ ├── explicit_output_overrides_alias.graphql-parsed.ron │ ├── explicit_output_overrides_alias.graphql.ron │ ├── explicit_output_overrides_alias.ir.ron │ ├── explicit_output_overrides_alias.output.ron │ ├── explicit_output_overrides_alias.trace.ron │ ├── filter_in_fold_using_external_tag.graphql-parsed.ron │ ├── filter_in_fold_using_external_tag.graphql.ron │ ├── filter_in_fold_using_external_tag.ir.ron │ ├── filter_in_fold_using_external_tag.output.ron │ ├── filter_in_fold_using_external_tag.trace.ron │ ├── filter_in_nested_fold_using_external_tag.graphql-parsed.ron │ ├── filter_in_nested_fold_using_external_tag.graphql.ron │ ├── filter_in_nested_fold_using_external_tag.ir.ron │ ├── filter_in_nested_fold_using_external_tag.output.ron │ ├── filter_in_nested_fold_using_external_tag.trace.ron │ ├── filter_op_contains.graphql-parsed.ron │ ├── filter_op_contains.graphql.ron │ ├── filter_op_contains.ir.ron │ ├── filter_op_contains.output.ron │ ├── filter_op_contains.trace.ron │ ├── filter_op_greater_or_equal.graphql-parsed.ron │ ├── filter_op_greater_or_equal.graphql.ron │ ├── filter_op_greater_or_equal.ir.ron │ ├── filter_op_greater_or_equal.output.ron │ ├── filter_op_greater_or_equal.trace.ron │ ├── filter_op_greater_than.graphql-parsed.ron │ ├── filter_op_greater_than.graphql.ron │ ├── filter_op_greater_than.ir.ron │ ├── filter_op_greater_than.output.ron │ ├── filter_op_greater_than.trace.ron │ ├── filter_op_has_prefix.graphql-parsed.ron │ ├── filter_op_has_prefix.graphql.ron │ ├── filter_op_has_prefix.ir.ron │ ├── filter_op_has_prefix.output.ron │ ├── filter_op_has_prefix.trace.ron │ ├── filter_op_has_substring.graphql-parsed.ron │ ├── filter_op_has_substring.graphql.ron │ ├── filter_op_has_substring.ir.ron │ ├── filter_op_has_substring.output.ron │ ├── filter_op_has_substring.trace.ron │ ├── filter_op_has_suffix.graphql-parsed.ron │ ├── filter_op_has_suffix.graphql.ron │ ├── filter_op_has_suffix.ir.ron │ ├── filter_op_has_suffix.output.ron │ ├── filter_op_has_suffix.trace.ron │ ├── filter_op_less_or_equal.graphql-parsed.ron │ ├── filter_op_less_or_equal.graphql.ron │ ├── filter_op_less_or_equal.ir.ron │ ├── filter_op_less_or_equal.output.ron │ ├── filter_op_less_or_equal.trace.ron │ ├── filter_op_less_than.graphql-parsed.ron │ ├── filter_op_less_than.graphql.ron │ ├── filter_op_less_than.ir.ron │ ├── filter_op_less_than.output.ron │ ├── filter_op_less_than.trace.ron │ ├── filter_op_not_equal.graphql-parsed.ron │ ├── filter_op_not_equal.graphql.ron │ ├── filter_op_not_equal.ir.ron │ ├── filter_op_not_equal.output.ron │ ├── filter_op_not_equal.trace.ron │ ├── filter_op_one_of.graphql-parsed.ron │ ├── filter_op_one_of.graphql.ron │ ├── filter_op_one_of.ir.ron │ ├── filter_op_one_of.output.ron │ ├── filter_op_one_of.trace.ron │ ├── filter_op_regex.graphql-parsed.ron │ ├── filter_op_regex.graphql.ron │ ├── filter_op_regex.ir.ron │ ├── filter_op_regex.output.ron │ ├── filter_op_regex.trace.ron │ ├── filter_with_omitted_value_arg.graphql-parsed.ron │ ├── filter_with_omitted_value_arg.graphql.ron │ ├── filter_with_omitted_value_arg.ir.ron │ ├── filter_with_omitted_value_arg.output.ron │ ├── filter_with_omitted_value_arg.trace.ron │ ├── filter_within_fold.graphql-parsed.ron │ ├── filter_within_fold.graphql.ron │ ├── filter_within_fold.ir.ron │ ├── filter_within_fold.output.ron │ ├── filter_within_fold.trace.ron │ ├── fold_count_filter.graphql-parsed.ron │ ├── fold_count_filter.graphql.ron │ ├── fold_count_filter.ir.ron │ ├── fold_count_filter.output.ron │ ├── fold_count_filter.trace.ron │ ├── fold_count_filter_early_prune_max_fold_size_equals.graphql-parsed.ron │ ├── fold_count_filter_early_prune_max_fold_size_equals.graphql.ron │ ├── fold_count_filter_early_prune_max_fold_size_equals.ir.ron │ ├── fold_count_filter_early_prune_max_fold_size_equals.output.ron │ ├── fold_count_filter_early_prune_max_fold_size_equals.trace.ron │ ├── fold_count_filter_early_prune_max_fold_size_less.graphql-parsed.ron │ ├── fold_count_filter_early_prune_max_fold_size_less.graphql.ron │ ├── fold_count_filter_early_prune_max_fold_size_less.ir.ron │ ├── fold_count_filter_early_prune_max_fold_size_less.output.ron │ ├── fold_count_filter_early_prune_max_fold_size_less.trace.ron │ ├── fold_count_filter_early_prune_max_fold_size_less_equals.graphql-parsed.ron │ ├── fold_count_filter_early_prune_max_fold_size_less_equals.graphql.ron │ ├── fold_count_filter_early_prune_max_fold_size_less_equals.ir.ron │ ├── fold_count_filter_early_prune_max_fold_size_less_equals.output.ron │ ├── fold_count_filter_early_prune_max_fold_size_less_equals.trace.ron │ ├── fold_count_filter_early_prune_max_fold_size_one_of.graphql-parsed.ron │ ├── fold_count_filter_early_prune_max_fold_size_one_of.graphql.ron │ ├── fold_count_filter_early_prune_max_fold_size_one_of.ir.ron │ ├── fold_count_filter_early_prune_max_fold_size_one_of.output.ron │ ├── fold_count_filter_early_prune_max_fold_size_one_of.trace.ron │ ├── fold_count_filter_eq_with_negative_arg.graphql-parsed.ron │ ├── fold_count_filter_eq_with_negative_arg.graphql.ron │ ├── fold_count_filter_eq_with_negative_arg.ir.ron │ ├── fold_count_filter_eq_with_negative_arg.output.ron │ ├── fold_count_filter_eq_with_negative_arg.trace.ron │ ├── fold_count_filter_gt_with_negative_arg.graphql-parsed.ron │ ├── fold_count_filter_gt_with_negative_arg.graphql.ron │ ├── fold_count_filter_gt_with_negative_arg.ir.ron │ ├── fold_count_filter_gt_with_negative_arg.output.ron │ ├── fold_count_filter_gt_with_negative_arg.trace.ron │ ├── fold_count_filter_gte_with_negative_arg.graphql-parsed.ron │ ├── fold_count_filter_gte_with_negative_arg.graphql.ron │ ├── fold_count_filter_gte_with_negative_arg.ir.ron │ ├── fold_count_filter_gte_with_negative_arg.output.ron │ ├── fold_count_filter_gte_with_negative_arg.trace.ron │ ├── fold_count_filter_lt_over_i64_max.graphql-parsed.ron │ ├── fold_count_filter_lt_over_i64_max.graphql.ron │ ├── fold_count_filter_lt_over_i64_max.ir.ron │ ├── fold_count_filter_lt_over_i64_max.output.ron │ ├── fold_count_filter_lt_over_i64_max.trace.ron │ ├── fold_count_filter_lt_with_negative_arg.graphql-parsed.ron │ ├── fold_count_filter_lt_with_negative_arg.graphql.ron │ ├── fold_count_filter_lt_with_negative_arg.ir.ron │ ├── fold_count_filter_lt_with_negative_arg.output.ron │ ├── fold_count_filter_lt_with_negative_arg.trace.ron │ ├── fold_count_filter_lte_with_negative_arg.graphql-parsed.ron │ ├── fold_count_filter_lte_with_negative_arg.graphql.ron │ ├── fold_count_filter_lte_with_negative_arg.ir.ron │ ├── fold_count_filter_lte_with_negative_arg.output.ron │ ├── fold_count_filter_lte_with_negative_arg.trace.ron │ ├── fold_count_filter_not_eq_with_negative_arg.graphql-parsed.ron │ ├── fold_count_filter_not_eq_with_negative_arg.graphql.ron │ ├── fold_count_filter_not_eq_with_negative_arg.ir.ron │ ├── fold_count_filter_not_eq_with_negative_arg.output.ron │ ├── fold_count_filter_not_eq_with_negative_arg.trace.ron │ ├── fold_count_filter_not_one_of_with_negative_arg.graphql-parsed.ron │ ├── fold_count_filter_not_one_of_with_negative_arg.graphql.ron │ ├── fold_count_filter_not_one_of_with_negative_arg.ir.ron │ ├── fold_count_filter_not_one_of_with_negative_arg.output.ron │ ├── fold_count_filter_not_one_of_with_negative_arg.trace.ron │ ├── fold_count_filter_on_a_tag.graphql-parsed.ron │ ├── fold_count_filter_on_a_tag.graphql.ron │ ├── fold_count_filter_on_a_tag.ir.ron │ ├── fold_count_filter_on_a_tag.output.ron │ ├── fold_count_filter_on_a_tag.trace.ron │ ├── fold_count_filter_one_of_with_negative_arg.graphql-parsed.ron │ ├── fold_count_filter_one_of_with_negative_arg.graphql.ron │ ├── fold_count_filter_one_of_with_negative_arg.ir.ron │ ├── fold_count_filter_one_of_with_negative_arg.output.ron │ ├── fold_count_filter_one_of_with_negative_arg.trace.ron │ ├── fold_count_filter_with_dominated_filter_gt.graphql-parsed.ron │ ├── fold_count_filter_with_dominated_filter_gt.graphql.ron │ ├── fold_count_filter_with_dominated_filter_gt.ir.ron │ ├── fold_count_filter_with_dominated_filter_gt.output.ron │ ├── fold_count_filter_with_dominated_filter_gt.trace.ron │ ├── fold_count_filter_with_dominated_filter_lt.graphql-parsed.ron │ ├── fold_count_filter_with_dominated_filter_lt.graphql.ron │ ├── fold_count_filter_with_dominated_filter_lt.ir.ron │ ├── fold_count_filter_with_dominated_filter_lt.output.ron │ ├── fold_count_filter_with_dominated_filter_lt.trace.ron │ ├── fold_count_filter_with_impossible_filter.graphql-parsed.ron │ ├── fold_count_filter_with_impossible_filter.graphql.ron │ ├── fold_count_filter_with_impossible_filter.ir.ron │ ├── fold_count_filter_with_impossible_filter.output.ron │ ├── fold_count_filter_with_impossible_filter.trace.ron │ ├── fold_count_filter_with_inner_filter.graphql-parsed.ron │ ├── fold_count_filter_with_inner_filter.graphql.ron │ ├── fold_count_filter_with_inner_filter.ir.ron │ ├── fold_count_filter_with_inner_filter.output.ron │ ├── fold_count_filter_with_inner_filter.trace.ron │ ├── fold_count_prefixed_output_name.graphql-parsed.ron │ ├── fold_count_prefixed_output_name.graphql.ron │ ├── fold_count_prefixed_output_name.ir.ron │ ├── fold_count_prefixed_output_name.output.ron │ ├── fold_count_prefixed_output_name.trace.ron │ ├── fold_count_tag_explicitly_named.graphql-parsed.ron │ ├── fold_count_tag_explicitly_named.graphql.ron │ ├── fold_count_tag_explicitly_named.ir.ron │ ├── fold_count_tag_explicitly_named.output.ron │ ├── fold_count_tag_explicitly_named.trace.ron │ ├── fold_count_tag_on_nonexistent_optional.graphql-parsed.ron │ ├── fold_count_tag_on_nonexistent_optional.graphql.ron │ ├── fold_count_tag_on_nonexistent_optional.ir.ron │ ├── fold_count_tag_on_nonexistent_optional.output.ron │ ├── fold_count_tag_on_nonexistent_optional.trace.ron │ ├── fold_count_tag_then_filter_on_fold.graphql-parsed.ron │ ├── fold_count_tag_then_filter_on_fold.graphql.ron │ ├── fold_count_tag_then_filter_on_fold.ir.ron │ ├── fold_count_tag_then_filter_on_fold.output.ron │ ├── fold_count_tag_then_filter_on_fold.trace.ron │ ├── fold_count_tag_used_inside_sibling_fold.graphql-parsed.ron │ ├── fold_count_tag_used_inside_sibling_fold.graphql.ron │ ├── fold_count_tag_used_inside_sibling_fold.ir.ron │ ├── fold_count_tag_used_inside_sibling_fold.output.ron │ ├── fold_count_tag_used_inside_sibling_fold.trace.ron │ ├── fold_directive.graphql-parsed.ron │ ├── fold_directive.graphql.ron │ ├── fold_directive.ir.ron │ ├── fold_directive.output.ron │ ├── fold_directive.trace.ron │ ├── fold_with_both_count_and_nested_filter_dependent_on_tag.graphql-parsed.ron │ ├── fold_with_both_count_and_nested_filter_dependent_on_tag.graphql.ron │ ├── fold_with_both_count_and_nested_filter_dependent_on_tag.ir.ron │ ├── fold_with_both_count_and_nested_filter_dependent_on_tag.output.ron │ ├── fold_with_both_count_and_nested_filter_dependent_on_tag.trace.ron │ ├── fold_with_count_filter_and_nested_filter.graphql-parsed.ron │ ├── fold_with_count_filter_and_nested_filter.graphql.ron │ ├── fold_with_count_filter_and_nested_filter.ir.ron │ ├── fold_with_count_filter_and_nested_filter.output.ron │ ├── fold_with_count_filter_and_nested_filter.trace.ron │ ├── fold_with_count_filter_and_nested_filter_with_tag.graphql-parsed.ron │ ├── fold_with_count_filter_and_nested_filter_with_tag.graphql.ron │ ├── fold_with_count_filter_and_nested_filter_with_tag.ir.ron │ ├── fold_with_count_filter_and_nested_filter_with_tag.output.ron │ ├── fold_with_count_filter_and_nested_filter_with_tag.trace.ron │ ├── fold_with_nested_filter.graphql-parsed.ron │ ├── fold_with_nested_filter.graphql.ron │ ├── fold_with_nested_filter.ir.ron │ ├── fold_with_nested_filter.output.ron │ ├── fold_with_nested_filter.trace.ron │ ├── fold_with_nested_filter_and_tag.graphql-parsed.ron │ ├── fold_with_nested_filter_and_tag.graphql.ron │ ├── fold_with_nested_filter_and_tag.ir.ron │ ├── fold_with_nested_filter_and_tag.output.ron │ ├── fold_with_nested_filter_and_tag.trace.ron │ ├── fold_with_no_inner_output_with_count_output.graphql-parsed.ron │ ├── fold_with_no_inner_output_with_count_output.graphql.ron │ ├── fold_with_no_inner_output_with_count_output.ir.ron │ ├── fold_with_no_inner_output_with_count_output.output.ron │ ├── fold_with_no_inner_output_with_count_output.trace.ron │ ├── fold_with_no_inner_output_with_count_tag.graphql-parsed.ron │ ├── fold_with_no_inner_output_with_count_tag.graphql.ron │ ├── fold_with_no_inner_output_with_count_tag.ir.ron │ ├── fold_with_no_inner_output_with_count_tag.output.ron │ ├── fold_with_no_inner_output_with_count_tag.trace.ron │ ├── fold_with_no_outputs.graphql-parsed.ron │ ├── fold_with_no_outputs.graphql.ron │ ├── fold_with_no_outputs.ir.ron │ ├── fold_with_no_outputs.output.ron │ ├── fold_with_no_outputs.trace.ron │ ├── fold_with_no_outputs_elided_braces.graphql-parsed.ron │ ├── fold_with_no_outputs_elided_braces.graphql.ron │ ├── fold_with_no_outputs_elided_braces.ir.ron │ ├── fold_with_no_outputs_elided_braces.output.ron │ ├── fold_with_no_outputs_elided_braces.trace.ron │ ├── fold_with_no_outputs_transform_and_filter_greater_than.graphql-parsed.ron │ ├── fold_with_no_outputs_transform_and_filter_greater_than.graphql.ron │ ├── fold_with_no_outputs_transform_and_filter_greater_than.ir.ron │ ├── fold_with_no_outputs_transform_and_filter_greater_than.output.ron │ ├── fold_with_no_outputs_transform_and_filter_greater_than.trace.ron │ ├── fold_with_no_outputs_transform_and_filter_less_than.graphql-parsed.ron │ ├── fold_with_no_outputs_transform_and_filter_less_than.graphql.ron │ ├── fold_with_no_outputs_transform_and_filter_less_than.ir.ron │ ├── fold_with_no_outputs_transform_and_filter_less_than.output.ron │ ├── fold_with_no_outputs_transform_and_filter_less_than.trace.ron │ ├── fold_with_no_outputs_transform_and_filter_one_of.graphql-parsed.ron │ ├── fold_with_no_outputs_transform_and_filter_one_of.graphql.ron │ ├── fold_with_no_outputs_transform_and_filter_one_of.ir.ron │ ├── fold_with_no_outputs_transform_and_filter_one_of.output.ron │ ├── fold_with_no_outputs_transform_and_filter_one_of.trace.ron │ ├── fold_with_nonexistent_optional.graphql-parsed.ron │ ├── fold_with_nonexistent_optional.graphql.ron │ ├── fold_with_nonexistent_optional.ir.ron │ ├── fold_with_nonexistent_optional.output.ron │ ├── fold_with_nonexistent_optional.trace.ron │ ├── fold_with_outputs_transform_and_filter_greater_than.graphql-parsed.ron │ ├── fold_with_outputs_transform_and_filter_greater_than.graphql.ron │ ├── fold_with_outputs_transform_and_filter_greater_than.ir.ron │ ├── fold_with_outputs_transform_and_filter_greater_than.output.ron │ ├── fold_with_outputs_transform_and_filter_greater_than.trace.ron │ ├── fold_with_outputs_transform_and_filter_less_than.graphql-parsed.ron │ ├── fold_with_outputs_transform_and_filter_less_than.graphql.ron │ ├── fold_with_outputs_transform_and_filter_less_than.ir.ron │ ├── fold_with_outputs_transform_and_filter_less_than.output.ron │ ├── fold_with_outputs_transform_and_filter_less_than.trace.ron │ ├── folded_filter_in_fold_using_external_tag.graphql-parsed.ron │ ├── folded_filter_in_fold_using_external_tag.graphql.ron │ ├── folded_filter_in_fold_using_external_tag.ir.ron │ ├── folded_filter_in_fold_using_external_tag.output.ron │ ├── folded_filter_in_fold_using_external_tag.trace.ron │ ├── implicit_coercion_in_recurse_to_supertype.graphql-parsed.ron │ ├── implicit_coercion_in_recurse_to_supertype.graphql.ron │ ├── implicit_coercion_in_recurse_to_supertype.ir.ron │ ├── implicit_coercion_in_recurse_to_supertype.output.ron │ ├── implicit_coercion_in_recurse_to_supertype.trace.ron │ ├── implicit_null_for_nullable_edge_parameter.graphql-parsed.ron │ ├── implicit_null_for_nullable_edge_parameter.graphql.ron │ ├── implicit_null_for_nullable_edge_parameter.ir.ron │ ├── implicit_null_for_nullable_edge_parameter.output.ron │ ├── implicit_null_for_nullable_edge_parameter.trace.ron │ ├── implicit_tag_and_output_names.graphql-parsed.ron │ ├── implicit_tag_and_output_names.graphql.ron │ ├── implicit_tag_and_output_names.ir.ron │ ├── implicit_tag_and_output_names.output.ron │ ├── implicit_tag_and_output_names.trace.ron │ ├── multiple_copies_of_field.graphql-parsed.ron │ ├── multiple_copies_of_field.graphql.ron │ ├── multiple_copies_of_field.ir.ron │ ├── multiple_copies_of_field.output.ron │ ├── multiple_copies_of_field.trace.ron │ ├── multiple_fold_count_outputs.graphql-parsed.ron │ ├── multiple_fold_count_outputs.graphql.ron │ ├── multiple_fold_count_outputs.ir.ron │ ├── multiple_fold_count_outputs.output.ron │ ├── multiple_fold_count_outputs.trace.ron │ ├── multiple_fold_outputs.graphql-parsed.ron │ ├── multiple_fold_outputs.graphql.ron │ ├── multiple_fold_outputs.ir.ron │ ├── multiple_fold_outputs.output.ron │ ├── multiple_fold_outputs.trace.ron │ ├── multiple_folds.graphql-parsed.ron │ ├── multiple_folds.graphql.ron │ ├── multiple_folds.ir.ron │ ├── multiple_folds.output.ron │ ├── multiple_folds.trace.ron │ ├── nested_fold.graphql-parsed.ron │ ├── nested_fold.graphql.ron │ ├── nested_fold.ir.ron │ ├── nested_fold.output.ron │ ├── nested_fold.trace.ron │ ├── nested_fold_count_output.graphql-parsed.ron │ ├── nested_fold_count_output.graphql.ron │ ├── nested_fold_count_output.ir.ron │ ├── nested_fold_count_output.output.ron │ ├── nested_fold_count_output.trace.ron │ ├── nested_fold_with_no_outputs.graphql-parsed.ron │ ├── nested_fold_with_no_outputs.graphql.ron │ ├── nested_fold_with_no_outputs.ir.ron │ ├── nested_fold_with_no_outputs.output.ron │ ├── nested_fold_with_no_outputs.trace.ron │ ├── nested_query.graphql-parsed.ron │ ├── nested_query.graphql.ron │ ├── nested_query.ir.ron │ ├── nested_query.output.ron │ ├── nested_query.trace.ron │ ├── no_op_fragment.graphql-parsed.ron │ ├── no_op_fragment.graphql.ron │ ├── no_op_fragment.ir.ron │ ├── no_op_fragment.output.ron │ ├── no_op_fragment.trace.ron │ ├── nonexistent_optional_with_immediate_coercion.graphql-parsed.ron │ ├── nonexistent_optional_with_immediate_coercion.graphql.ron │ ├── nonexistent_optional_with_immediate_coercion.ir.ron │ ├── nonexistent_optional_with_immediate_coercion.output.ron │ ├── nonexistent_optional_with_immediate_coercion.trace.ron │ ├── nonexistent_optional_with_immediate_filter.graphql-parsed.ron │ ├── nonexistent_optional_with_immediate_filter.graphql.ron │ ├── nonexistent_optional_with_immediate_filter.ir.ron │ ├── nonexistent_optional_with_immediate_filter.output.ron │ ├── nonexistent_optional_with_immediate_filter.trace.ron │ ├── nonexistent_optional_with_immediate_is_not_null_filter.graphql-parsed.ron │ ├── nonexistent_optional_with_immediate_is_not_null_filter.graphql.ron │ ├── nonexistent_optional_with_immediate_is_not_null_filter.ir.ron │ ├── nonexistent_optional_with_immediate_is_not_null_filter.output.ron │ ├── nonexistent_optional_with_immediate_is_not_null_filter.trace.ron │ ├── nonexistent_optional_with_nested_coercion.graphql-parsed.ron │ ├── nonexistent_optional_with_nested_coercion.graphql.ron │ ├── nonexistent_optional_with_nested_coercion.ir.ron │ ├── nonexistent_optional_with_nested_coercion.output.ron │ ├── nonexistent_optional_with_nested_coercion.trace.ron │ ├── nonexistent_optional_with_nested_filter.graphql-parsed.ron │ ├── nonexistent_optional_with_nested_filter.graphql.ron │ ├── nonexistent_optional_with_nested_filter.ir.ron │ ├── nonexistent_optional_with_nested_filter.output.ron │ ├── nonexistent_optional_with_nested_filter.trace.ron │ ├── nonexistent_optional_with_nested_fold.graphql-parsed.ron │ ├── nonexistent_optional_with_nested_fold.graphql.ron │ ├── nonexistent_optional_with_nested_fold.ir.ron │ ├── nonexistent_optional_with_nested_fold.output.ron │ ├── nonexistent_optional_with_nested_fold.trace.ron │ ├── nonexistent_optional_with_nested_is_not_null_filter.graphql-parsed.ron │ ├── nonexistent_optional_with_nested_is_not_null_filter.graphql.ron │ ├── nonexistent_optional_with_nested_is_not_null_filter.ir.ron │ ├── nonexistent_optional_with_nested_is_not_null_filter.output.ron │ ├── nonexistent_optional_with_nested_is_not_null_filter.trace.ron │ ├── nonexistent_optional_with_nested_optional.graphql-parsed.ron │ ├── nonexistent_optional_with_nested_optional.graphql.ron │ ├── nonexistent_optional_with_nested_optional.ir.ron │ ├── nonexistent_optional_with_nested_optional.output.ron │ ├── nonexistent_optional_with_nested_optional.trace.ron │ ├── nonexistent_optional_with_tagged_immediate_filter.graphql-parsed.ron │ ├── nonexistent_optional_with_tagged_immediate_filter.graphql.ron │ ├── nonexistent_optional_with_tagged_immediate_filter.ir.ron │ ├── nonexistent_optional_with_tagged_immediate_filter.output.ron │ ├── nonexistent_optional_with_tagged_immediate_filter.trace.ron │ ├── nonexistent_optional_with_tagged_nested_filter.graphql-parsed.ron │ ├── nonexistent_optional_with_tagged_nested_filter.graphql.ron │ ├── nonexistent_optional_with_tagged_nested_filter.ir.ron │ ├── nonexistent_optional_with_tagged_nested_filter.output.ron │ ├── nonexistent_optional_with_tagged_nested_filter.trace.ron │ ├── optional_directive.graphql-parsed.ron │ ├── optional_directive.graphql.ron │ ├── optional_directive.ir.ron │ ├── optional_directive.output.ron │ ├── optional_directive.trace.ron │ ├── optional_with_nested_edge_and_filter.graphql-parsed.ron │ ├── optional_with_nested_edge_and_filter.graphql.ron │ ├── optional_with_nested_edge_and_filter.ir.ron │ ├── optional_with_nested_edge_and_filter.output.ron │ ├── optional_with_nested_edge_and_filter.trace.ron │ ├── optional_with_nested_edge_with_filter_and_tag.graphql-parsed.ron │ ├── optional_with_nested_edge_with_filter_and_tag.graphql.ron │ ├── optional_with_nested_edge_with_filter_and_tag.ir.ron │ ├── optional_with_nested_edge_with_filter_and_tag.output.ron │ ├── optional_with_nested_edge_with_filter_and_tag.trace.ron │ ├── optional_with_nested_filter_semantics.graphql-parsed.ron │ ├── optional_with_nested_filter_semantics.graphql.ron │ ├── optional_with_nested_filter_semantics.ir.ron │ ├── optional_with_nested_filter_semantics.output.ron │ ├── optional_with_nested_filter_semantics.trace.ron │ ├── optional_with_nested_filter_with_tag_semantics.graphql-parsed.ron │ ├── optional_with_nested_filter_with_tag_semantics.graphql.ron │ ├── optional_with_nested_filter_with_tag_semantics.ir.ron │ ├── optional_with_nested_filter_with_tag_semantics.output.ron │ ├── optional_with_nested_filter_with_tag_semantics.trace.ron │ ├── optional_with_nested_required_edge_semantics.graphql-parsed.ron │ ├── optional_with_nested_required_edge_semantics.graphql.ron │ ├── optional_with_nested_required_edge_semantics.ir.ron │ ├── optional_with_nested_required_edge_semantics.output.ron │ ├── optional_with_nested_required_edge_semantics.trace.ron │ ├── output_fold_count.graphql-parsed.ron │ ├── output_fold_count.graphql.ron │ ├── output_fold_count.ir.ron │ ├── output_fold_count.output.ron │ ├── output_fold_count.trace.ron │ ├── output_fold_count_multiple.graphql-parsed.ron │ ├── output_fold_count_multiple.graphql.ron │ ├── output_fold_count_multiple.ir.ron │ ├── output_fold_count_multiple.output.ron │ ├── output_fold_count_multiple.trace.ron │ ├── outputs_both_inside_and_outside_fold.graphql-parsed.ron │ ├── outputs_both_inside_and_outside_fold.graphql.ron │ ├── outputs_both_inside_and_outside_fold.ir.ron │ ├── outputs_both_inside_and_outside_fold.output.ron │ ├── outputs_both_inside_and_outside_fold.trace.ron │ ├── recurse_and_traverse.graphql-parsed.ron │ ├── recurse_and_traverse.graphql.ron │ ├── recurse_and_traverse.ir.ron │ ├── recurse_and_traverse.output.ron │ ├── recurse_and_traverse.trace.ron │ ├── recurse_directive.graphql-parsed.ron │ ├── recurse_directive.graphql.ron │ ├── recurse_directive.ir.ron │ ├── recurse_directive.output.ron │ ├── recurse_directive.trace.ron │ ├── recurse_on_parameterized_edge.graphql-parsed.ron │ ├── recurse_on_parameterized_edge.graphql.ron │ ├── recurse_on_parameterized_edge.ir.ron │ ├── recurse_on_parameterized_edge.output.ron │ ├── recurse_on_parameterized_edge.trace.ron │ ├── recurse_then_filter_depth_one.graphql-parsed.ron │ ├── recurse_then_filter_depth_one.graphql.ron │ ├── recurse_then_filter_depth_one.ir.ron │ ├── recurse_then_filter_depth_one.output.ron │ ├── recurse_then_filter_depth_one.trace.ron │ ├── recurse_then_filter_depth_two.graphql-parsed.ron │ ├── recurse_then_filter_depth_two.graphql.ron │ ├── recurse_then_filter_depth_two.ir.ron │ ├── recurse_then_filter_depth_two.output.ron │ ├── recurse_then_filter_depth_two.trace.ron │ ├── recurse_then_filter_intermediate.graphql-parsed.ron │ ├── recurse_then_filter_intermediate.graphql.ron │ ├── recurse_then_filter_intermediate.ir.ron │ ├── recurse_then_filter_intermediate.output.ron │ ├── recurse_then_filter_intermediate.trace.ron │ ├── recurse_then_filter_leaves.graphql-parsed.ron │ ├── recurse_then_filter_leaves.graphql.ron │ ├── recurse_then_filter_leaves.ir.ron │ ├── recurse_then_filter_leaves.output.ron │ ├── recurse_then_filter_leaves.trace.ron │ ├── recurse_then_filter_on_tag_depth_one.graphql-parsed.ron │ ├── recurse_then_filter_on_tag_depth_one.graphql.ron │ ├── recurse_then_filter_on_tag_depth_one.ir.ron │ ├── recurse_then_filter_on_tag_depth_one.output.ron │ ├── recurse_then_filter_on_tag_depth_one.trace.ron │ ├── recurse_then_filter_on_tag_depth_two.graphql-parsed.ron │ ├── recurse_then_filter_on_tag_depth_two.graphql.ron │ ├── recurse_then_filter_on_tag_depth_two.ir.ron │ ├── recurse_then_filter_on_tag_depth_two.output.ron │ ├── recurse_then_filter_on_tag_depth_two.trace.ron │ ├── recurse_then_nested_required_edge_depth_two.graphql-parsed.ron │ ├── recurse_then_nested_required_edge_depth_two.graphql.ron │ ├── recurse_then_nested_required_edge_depth_two.ir.ron │ ├── recurse_then_nested_required_edge_depth_two.output.ron │ ├── recurse_then_nested_required_edge_depth_two.trace.ron │ ├── recurse_then_required_edge_depth_one.graphql-parsed.ron │ ├── recurse_then_required_edge_depth_one.graphql.ron │ ├── recurse_then_required_edge_depth_one.ir.ron │ ├── recurse_then_required_edge_depth_one.output.ron │ ├── recurse_then_required_edge_depth_one.trace.ron │ ├── required_properties.graphql-parsed.ron │ ├── required_properties.graphql.ron │ ├── required_properties.ir.ron │ ├── required_properties.output.ron │ ├── required_properties.trace.ron │ ├── required_properties_filter_and_output.graphql-parsed.ron │ ├── required_properties_filter_and_output.graphql.ron │ ├── required_properties_filter_and_output.ir.ron │ ├── required_properties_filter_and_output.output.ron │ ├── required_properties_filter_and_output.trace.ron │ ├── root_coercion.graphql-parsed.ron │ ├── root_coercion.graphql.ron │ ├── root_coercion.ir.ron │ ├── root_coercion.output.ron │ ├── root_coercion.trace.ron │ ├── simple_filter.graphql-parsed.ron │ ├── simple_filter.graphql.ron │ ├── simple_filter.ir.ron │ ├── simple_filter.output.ron │ ├── simple_filter.trace.ron │ ├── simple_query.graphql-parsed.ron │ ├── simple_query.graphql.ron │ ├── simple_query.ir.ron │ ├── simple_query.output.ron │ ├── simple_query.trace.ron │ ├── static_and_dynamic_filter.graphql-parsed.ron │ ├── static_and_dynamic_filter.graphql.ron │ ├── static_and_dynamic_filter.ir.ron │ ├── static_and_dynamic_filter.output.ron │ ├── static_and_dynamic_filter.trace.ron │ ├── tag_and_filter_directives.graphql-parsed.ron │ ├── tag_and_filter_directives.graphql.ron │ ├── tag_and_filter_directives.ir.ron │ ├── tag_and_filter_directives.output.ron │ ├── tag_and_filter_directives.trace.ron │ ├── tag_before_filter_in_same_scope.graphql-parsed.ron │ ├── tag_before_filter_in_same_scope.graphql.ron │ ├── tag_before_filter_in_same_scope.ir.ron │ ├── tag_before_filter_in_same_scope.output.ron │ ├── tag_before_filter_in_same_scope.trace.ron │ ├── tag_name_in_prefixed_vertex.graphql-parsed.ron │ ├── tag_name_in_prefixed_vertex.graphql.ron │ ├── tag_name_in_prefixed_vertex.ir.ron │ ├── tag_name_in_prefixed_vertex.output.ron │ ├── tag_name_in_prefixed_vertex.trace.ron │ ├── tag_within_non_existent_optional.graphql-parsed.ron │ ├── tag_within_non_existent_optional.graphql.ron │ ├── tag_within_non_existent_optional.ir.ron │ ├── tag_within_non_existent_optional.output.ron │ ├── tag_within_non_existent_optional.trace.ron │ ├── tag_within_non_existent_optional_used_in_fold.graphql-parsed.ron │ ├── tag_within_non_existent_optional_used_in_fold.graphql.ron │ ├── tag_within_non_existent_optional_used_in_fold.ir.ron │ ├── tag_within_non_existent_optional_used_in_fold.output.ron │ ├── tag_within_non_existent_optional_used_in_fold.trace.ron │ ├── typename_filter.graphql-parsed.ron │ ├── typename_filter.graphql.ron │ ├── typename_filter.ir.ron │ ├── typename_filter.output.ron │ ├── typename_filter.trace.ron │ ├── typename_output.graphql-parsed.ron │ ├── typename_output.graphql.ron │ ├── typename_output.ir.ron │ ├── typename_output.output.ron │ ├── typename_output.trace.ron │ ├── typename_output_on_final_type.graphql-parsed.ron │ ├── typename_output_on_final_type.graphql.ron │ ├── typename_output_on_final_type.ir.ron │ ├── typename_output_on_final_type.output.ron │ ├── typename_output_on_final_type.trace.ron │ ├── typename_tag_and_filter.graphql-parsed.ron │ ├── typename_tag_and_filter.graphql.ron │ ├── typename_tag_and_filter.ir.ron │ ├── typename_tag_and_filter.output.ron │ ├── typename_tag_and_filter.trace.ron │ ├── zero_element_fold_with_doubly_nested_folds.graphql-parsed.ron │ ├── zero_element_fold_with_doubly_nested_folds.graphql.ron │ ├── zero_element_fold_with_doubly_nested_folds.ir.ron │ ├── zero_element_fold_with_doubly_nested_folds.output.ron │ ├── zero_element_fold_with_doubly_nested_folds.trace.ron │ ├── zero_element_fold_with_nested_edge.graphql-parsed.ron │ ├── zero_element_fold_with_nested_edge.graphql.ron │ ├── zero_element_fold_with_nested_edge.ir.ron │ ├── zero_element_fold_with_nested_edge.output.ron │ ├── zero_element_fold_with_nested_edge.trace.ron │ ├── zero_element_fold_with_nested_fold.graphql-parsed.ron │ ├── zero_element_fold_with_nested_fold.graphql.ron │ ├── zero_element_fold_with_nested_fold.ir.ron │ ├── zero_element_fold_with_nested_fold.output.ron │ ├── zero_element_fold_with_nested_fold.trace.ron │ ├── zero_element_fold_with_nested_optional_edge.graphql-parsed.ron │ ├── zero_element_fold_with_nested_optional_edge.graphql.ron │ ├── zero_element_fold_with_nested_optional_edge.ir.ron │ ├── zero_element_fold_with_nested_optional_edge.output.ron │ └── zero_element_fold_with_nested_optional_edge.trace.ron │ └── valid_schemas │ ├── deeply_nested_list_property_field.graphql │ ├── type_narrowing_edge_nullability.graphql │ ├── type_narrowing_edge_subtype.graphql │ ├── type_narrowing_list_edge_nullability.graphql │ ├── type_narrowing_list_edge_subtype.graphql │ ├── type_narrowing_of_inherited_fields.graphql │ └── type_widening_parameterized_field_parameter.graphql ├── trustfall_derive ├── .gitignore ├── Cargo.toml ├── LICENSE.txt ├── src │ └── lib.rs └── tests │ ├── ui │ ├── call_skipped_conversion.rs │ ├── call_skipped_conversion.stderr │ ├── derive_struct.rs │ ├── derive_struct.stderr │ ├── invalid_attr_as_path_only.rs │ ├── invalid_attr_as_path_only.stderr │ ├── invalid_attr_unexpected_assignment.rs │ ├── invalid_attr_unexpected_assignment.stderr │ ├── invalid_attr_unexpected_list_element.rs │ ├── invalid_attr_unexpected_list_element.stderr │ ├── syntax_error.rs.broken │ └── syntax_error.rs.stderr │ └── uses.rs ├── trustfall_filetests_macros ├── Cargo.toml ├── LICENSE.txt └── src │ └── lib.rs ├── trustfall_stubgen ├── Cargo.toml ├── LICENSE.txt ├── README.md ├── src │ ├── adapter_creator.rs │ ├── edges_creator.rs │ ├── entrypoints_creator.rs │ ├── lib.rs │ ├── main.rs │ ├── properties_creator.rs │ ├── root.rs │ ├── tests.rs │ └── util.rs └── test_data │ ├── expected_outputs │ ├── hackernews │ │ └── adapter │ │ │ ├── adapter_impl.rs │ │ │ ├── edges.rs │ │ │ ├── entrypoints.rs │ │ │ ├── mod.rs │ │ │ ├── properties.rs │ │ │ ├── schema.graphql │ │ │ ├── tests.rs │ │ │ └── vertex.rs │ ├── no_edges │ │ └── adapter │ │ │ ├── adapter_impl.rs │ │ │ ├── edges.rs │ │ │ ├── entrypoints.rs │ │ │ ├── mod.rs │ │ │ ├── properties.rs │ │ │ ├── schema.graphql │ │ │ ├── tests.rs │ │ │ └── vertex.rs │ └── use_reserved_rust_names_in_schema │ │ └── adapter │ │ ├── adapter_impl.rs │ │ ├── edges.rs │ │ ├── entrypoints.rs │ │ ├── mod.rs │ │ ├── properties.rs │ │ ├── schema.graphql │ │ ├── tests.rs │ │ └── vertex.rs │ ├── hackernews.graphql │ ├── no_edges.graphql │ ├── use_reserved_rust_names_in_schema.graphql │ ├── use_type_and_typeunderscore_edge_names.graphql │ ├── vertextype_with_type_and_typeunderscore_edge_and_property.graphql │ ├── vertextype_with_type_and_typeunderscore_edges.graphql │ └── vertextype_with_type_and_typeunderscore_properties.graphql ├── trustfall_testbin ├── Cargo.toml ├── LICENSE.txt └── src │ └── main.rs └── trustfall_wasm ├── Cargo.toml ├── LICENSE.txt ├── README.md ├── src ├── adapter.rs ├── lib.rs ├── shim.rs ├── trustfall_wasm.d.ts └── util.rs ├── tests ├── common.rs ├── nodejs.rs └── web.rs └── www ├── .gitignore ├── README.md ├── bootstrap.js ├── index.html ├── index.js ├── package-lock.json ├── package.json └── webpack.config.js /.github/dependabot.yml: -------------------------------------------------------------------------------- 1 | version: 2 2 | updates: 3 | - package-ecosystem: "github-actions" 4 | directory: "/" 5 | schedule: 6 | interval: "weekly" 7 | day: "saturday" 8 | time: "00:39" 9 | timezone: "America/New_York" 10 | -------------------------------------------------------------------------------- /.github/workflows/get_current_crate_version.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | # Script requirements: 4 | # - jq 5 | 6 | # Fail on first error, on undefined variables, and on failures in pipelines. 7 | set -euo pipefail 8 | 9 | # Go to the repo root directory. 10 | cd "$(git rev-parse --show-toplevel)" 11 | 12 | # The first argument should be the name of a crate. 13 | CRATE_NAME="$1" 14 | 15 | cargo metadata --no-deps --format-version 1 | \ 16 | jq --arg crate_name "$CRATE_NAME" --exit-status -r \ 17 | '.packages[] | select(.name == $crate_name) | .version' 18 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | **/target 2 | **/.vscode/ 3 | **/.idea/ 4 | **/.cargo/ 5 | **/localdata/ 6 | **/.ipynb_checkpoints/ 7 | 8 | **/*.pyc 9 | **/*.pyo 10 | **/*.pyx 11 | **/__pycache__/ 12 | **/trustfall.cpython-*.so 13 | **/.pytest_cache/ 14 | -------------------------------------------------------------------------------- /CODEOWNERS: -------------------------------------------------------------------------------- 1 | # *IMPORTANT*: Last rule wins in this file. 2 | 3 | 4 | # *IMPORTANT*: This must be the last rule. 5 | # The .github directory is very sensitive: 6 | # - It contains settings.yml, which affects repo-wide config; 7 | # writing that file is equivalent to being a repo admin. 8 | # - it contains the GitHub Actions workflows, which can access repo secrets. 9 | .github/ @obi1kenobi 10 | -------------------------------------------------------------------------------- /demo-hytradboi/example_queries/repos_with_min_50_hackernews_points.ron: -------------------------------------------------------------------------------- 1 | InputQuery ( 2 | query: r#" 3 | { 4 | HackerNewsTop(max: 1000) { 5 | ... on HackerNewsStory { 6 | score @filter(op: ">=", value: ["$min_score"]) 7 | @output 8 | 9 | link { 10 | ... on GitHubRepository { 11 | url @output 12 | } 13 | } 14 | } 15 | } 16 | }"#, 17 | args: { 18 | "min_score": Uint64(50), 19 | } 20 | ) 21 | -------------------------------------------------------------------------------- /demo-hytradboi/query-demo.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/obi1kenobi/trustfall/400f2dde891efdf19c3eb7b0b35903f9a1517413/demo-hytradboi/query-demo.gif -------------------------------------------------------------------------------- /experiments/browser_based_querying/.gitignore: -------------------------------------------------------------------------------- 1 | trustfall_wasm.tar.gz 2 | **/node_modules 3 | **/www 4 | **/www2 5 | **/__pycache__ 6 | **/dist 7 | -------------------------------------------------------------------------------- /experiments/browser_based_querying/.prettierignore: -------------------------------------------------------------------------------- 1 | www2 2 | -------------------------------------------------------------------------------- /experiments/browser_based_querying/babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: [ 3 | '@babel/preset-typescript', 4 | ['@babel/preset-react', { runtime: 'automatic', importSource: '@emotion/react' }], 5 | ], 6 | plugins: ['@emotion/babel-plugin'], 7 | }; 8 | -------------------------------------------------------------------------------- /experiments/browser_based_querying/example_queries/rustdoc/iter_structs.example: -------------------------------------------------------------------------------- 1 | # Structs whose names end in "Iter": not all crates have them, 2 | # so try one of these crates: arrayvec, indexmap, itertools 3 | query { 4 | Crate { 5 | item { 6 | ... on Struct { 7 | name @output @filter(op: "has_suffix", value: ["$suffix"]) 8 | 9 | span { 10 | filename @output 11 | first_line: begin_line @output 12 | } 13 | } 14 | } 15 | } 16 | } 17 | 18 | vars: 19 | { 20 | "suffix": "Iter" 21 | } 22 | -------------------------------------------------------------------------------- /experiments/browser_based_querying/example_queries/rustdoc/struct_names_and_spans.example: -------------------------------------------------------------------------------- 1 | # Structs in this crate and where (file + line number) they were defined 2 | query { 3 | Crate { 4 | item { 5 | ... on Struct { 6 | name @output 7 | 8 | span { 9 | filename @output 10 | first_line: begin_line @output 11 | } 12 | } 13 | } 14 | } 15 | } 16 | 17 | vars: 18 | { 19 | 20 | } 21 | -------------------------------------------------------------------------------- /experiments/browser_based_querying/example_queries/rustdoc/structs_and_fields.example: -------------------------------------------------------------------------------- 1 | # Structs and a list of their field names. 2 | query { 3 | Crate { 4 | item { 5 | ... on Struct { 6 | name @output # by default, outputs use the name of their field 7 | 8 | field @fold { 9 | fields: name @output # renamed output to avoid name collision 10 | } 11 | } 12 | } 13 | } 14 | } 15 | 16 | vars: 17 | { 18 | 19 | } 20 | -------------------------------------------------------------------------------- /experiments/browser_based_querying/index.d.ts: -------------------------------------------------------------------------------- 1 | // Tell Typescript to interpret imports of .example files as strings 2 | declare module '*.example' { 3 | const content: string; 4 | export default content; 5 | } 6 | 7 | // Tell Typescript to interpret imports of .graphql files as strings 8 | declare module '*.graphql' { 9 | const content: string; 10 | export default content; 11 | } 12 | -------------------------------------------------------------------------------- /experiments/browser_based_querying/prettier.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | tabWidth: 2, 3 | semi: true, 4 | singleQuote: true, 5 | trailingComma: 'es5', 6 | printWidth: 100, 7 | }; 8 | -------------------------------------------------------------------------------- /experiments/browser_based_querying/src/components/DocExplorer/Styles.tsx: -------------------------------------------------------------------------------- 1 | const styles = { 2 | argument: { 3 | color: '#a43fc0', 4 | fontSize: 16, 5 | }, 6 | type: { 7 | color: '#FD9E02', 8 | }, 9 | typesTitle: { 10 | color: 'darkgray', 11 | textTransform: 'uppercase', 12 | mb: 0.8, 13 | }, 14 | searchResultTitles: { 15 | fontWeight: 'bold', 16 | color: 'dimgray', 17 | mt: 1, 18 | }, 19 | typeDocumentation: { 20 | color: 'dimgray', 21 | }, 22 | }; 23 | export default styles; 24 | -------------------------------------------------------------------------------- /experiments/browser_based_querying/src/index.tsx: -------------------------------------------------------------------------------- 1 | import 'core-js/stable'; 2 | import { render } from 'react-dom'; 3 | import { createRoot } from 'react-dom/client'; 4 | 5 | import App from './App'; 6 | 7 | const mainEl = document.getElementsByTagName('main')[0]; 8 | const root = createRoot(mainEl); 9 | root.render(); 10 | if (process.env.NODE_ENV === 'development' && module.hot) { 11 | module.hot.accept('./App', () => render(, mainEl)); 12 | } 13 | -------------------------------------------------------------------------------- /experiments/browser_based_querying/src/types.ts: -------------------------------------------------------------------------------- 1 | export type AsyncValue = 2 | | { status: 'pending' } 3 | | { status: 'ready'; value: T } 4 | | { status: 'error'; error: E }; 5 | -------------------------------------------------------------------------------- /experiments/browser_based_querying/src/utils/debug.ts: -------------------------------------------------------------------------------- 1 | export default function debug(...outputs: unknown[]): void { 2 | console.debug("[Trustfall]", ...outputs); 3 | } 4 | -------------------------------------------------------------------------------- /experiments/schemaless/Cargo.toml: -------------------------------------------------------------------------------- 1 | [package] 2 | name = "schemaless" 3 | version = "0.1.0" 4 | edition = "2021" 5 | 6 | # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html 7 | 8 | [dependencies] 9 | async-graphql-parser = { workspace = true } 10 | async-graphql-value = { workspace = true } 11 | derive-new = "0.5.9" 12 | maplit = { workspace = true } 13 | trustfall_core = { path = "../../trustfall_core" } 14 | -------------------------------------------------------------------------------- /experiments/schemaless/example_queries/repos_with_min_hackernews_points.graphql: -------------------------------------------------------------------------------- 1 | { 2 | HackerNewsTop(max: 1000) { 3 | ... on HackerNewsStory { 4 | score @filter(op: ">=", value: ["$min_score"]) 5 | @output 6 | 7 | link { 8 | ... on GitHubRepository { 9 | url @output 10 | } 11 | } 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /experiments/schemaless/src/lib.rs: -------------------------------------------------------------------------------- 1 | mod schema_inference; 2 | 3 | #[macro_use] 4 | extern crate maplit; 5 | 6 | pub use crate::schema_inference::infer_schema_from_query; 7 | -------------------------------------------------------------------------------- /experiments/schemaless_wasm/www/.eslintrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "parser": "@typescript-eslint/parser", 3 | "extends": [ 4 | "eslint:recommended", 5 | "plugin:react/recommended", 6 | "plugin:react-hooks/recommended", 7 | "typescript", 8 | "plugin:@typescript-eslint/recommended" 9 | ], 10 | "env": { 11 | "node": true 12 | }, 13 | "rules": { 14 | "@typescript-eslint/no-var-requires": 0 15 | }, 16 | "settings": { 17 | "react": { 18 | "version": "18" 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /experiments/schemaless_wasm/www/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | dist 3 | -------------------------------------------------------------------------------- /experiments/schemaless_wasm/www/babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: ['@babel/preset-typescript', '@babel/preset-react'], 3 | }; 4 | -------------------------------------------------------------------------------- /experiments/schemaless_wasm/www/prettier.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | tabWidth: 4, 3 | semi: true, 4 | singleQuote: true, 5 | trailingComma: 'es5', 6 | printWidth: 100, 7 | }; 8 | -------------------------------------------------------------------------------- /experiments/schemaless_wasm/www/src/bootstrap.ts: -------------------------------------------------------------------------------- 1 | // A dependency graph that contains any wasm must all be imported 2 | // asynchronously. This `bootstrap.ts` file does the single async import, so 3 | // that no one else needs to worry about it again. 4 | import('./index').catch((e) => console.error('Error importing `index.ts`:', e)); 5 | -------------------------------------------------------------------------------- /experiments/schemaless_wasm/www/src/index.ejs: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | <%= htmlWebpackPlugin.options.title %> 7 | 11 | 12 | 13 | 14 | 15 | 16 |
17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /experiments/schemaless_wasm/www/src/index.tsx: -------------------------------------------------------------------------------- 1 | import 'core-js/stable'; 2 | import * as React from 'react'; 3 | import { render } from 'react-dom'; 4 | import { createRoot } from 'react-dom/client'; 5 | 6 | import App from './App'; 7 | 8 | const mainEl = document.getElementsByTagName('main')[0]; 9 | const root = createRoot(mainEl); 10 | root.render(); 11 | if (process.env.NODE_ENV === 'development' && module.hot) { 12 | module.hot.accept('./App', () => render(, mainEl)); 13 | } 14 | -------------------------------------------------------------------------------- /experiments/schemaless_wasm/www/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "forceConsistentCasingInFileNames": true, 4 | "jsx": "react", 5 | "module": "esnext", 6 | "moduleResolution": "node", 7 | "noEmit": true, 8 | "noFallthroughCasesInSwitch": true, 9 | "noImplicitReturns": true, 10 | "noUnusedLocals": true, 11 | "noUnusedParameters": true, 12 | "strict": true, 13 | "target": "es2017", 14 | "allowSyntheticDefaultImports": true 15 | } 16 | } 17 | -------------------------------------------------------------------------------- /experiments/trustfall_rustdoc/README.md: -------------------------------------------------------------------------------- 1 | # trustfall_rustdoc 2 | 3 | WASM implementation of querying rustdoc JSON output. 4 | 5 | To build it for a web target, run the following from the `trustfall_rustdoc` directory: 6 | ```console 7 | wasm-pack build --no-typescript --target web 8 | cp ./src/trustfall_rustdoc.d.ts ./pkg/ 9 | ``` 10 | 11 | To run the test suite in a headless Firefox browser, run: 12 | ```console 13 | wasm-pack test --headless --firefox 14 | ``` 15 | -------------------------------------------------------------------------------- /pytrustfall/trustfall/py.typed: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/obi1kenobi/trustfall/400f2dde891efdf19c3eb7b0b35903f9a1517413/pytrustfall/trustfall/py.typed -------------------------------------------------------------------------------- /pytrustfall/trustfall/tests/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/obi1kenobi/trustfall/400f2dde891efdf19c3eb7b0b35903f9a1517413/pytrustfall/trustfall/tests/__init__.py -------------------------------------------------------------------------------- /rustfmt.toml: -------------------------------------------------------------------------------- 1 | # Rust code formatting; see https://rust-lang.github.io/rustfmt 2 | use_small_heuristics = "Max" 3 | -------------------------------------------------------------------------------- /scripts/recreate_all_execution_errors.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | # Fail on first error, on undefined variables, and on failures in pipelines. 4 | set -euo pipefail 5 | 6 | # Move relative to the top of the repo, so this script can be run from anywhere. 7 | cd "$(git rev-parse --show-toplevel)/trustfall_testbin" 8 | 9 | find ../trustfall_core/test_data/tests/execution_errors -name '*.ir.ron' | \ 10 | xargs -n 1 \ 11 | sh -c 'cargo run trace $0 >"$(dirname $0)/$(basename $0 | cut -d'.' -f1).exec-error.ron"' 12 | -------------------------------------------------------------------------------- /scripts/recreate_all_frontend_errors.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | # Fail on first error, on undefined variables, and on failures in pipelines. 4 | set -euo pipefail 5 | 6 | # Move relative to the top of the repo, so this script can be run from anywhere. 7 | cd "$(git rev-parse --show-toplevel)/trustfall_testbin" 8 | 9 | find ../trustfall_core/test_data/tests/frontend_errors -name '*.graphql-parsed.ron' | \ 10 | xargs -n 1 \ 11 | sh -c 'cargo run frontend $0 >"$(dirname $0)/$(basename $0 | cut -d'.' -f1).frontend-error.ron"' 12 | -------------------------------------------------------------------------------- /scripts/recreate_all_outputs.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | # Fail on first error, on undefined variables, and on failures in pipelines. 4 | set -euo pipefail 5 | 6 | # Move relative to the top of the repo, so this script can be run from anywhere. 7 | cd "$(git rev-parse --show-toplevel)/trustfall_testbin" 8 | 9 | find ../trustfall_core/test_data/tests/valid_queries -name '*.ir.ron' | \ 10 | xargs -n 1 \ 11 | sh -c 'cargo run outputs $0 >"$(dirname $0)/$(basename $0 | cut -d'.' -f1).output.ron"' 12 | -------------------------------------------------------------------------------- /scripts/recreate_all_parse_errors.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | # Fail on first error, on undefined variables, and on failures in pipelines. 4 | set -euo pipefail 5 | 6 | # Move relative to the top of the repo, so this script can be run from anywhere. 7 | cd "$(git rev-parse --show-toplevel)/trustfall_testbin" 8 | 9 | find ../trustfall_core/test_data/tests/parse_errors -name '*.graphql.ron' | \ 10 | xargs -n 1 \ 11 | sh -c 'cargo run parse $0 >"$(dirname $0)/$(basename $0 | cut -d'.' -f1).parse-error.ron"' 12 | -------------------------------------------------------------------------------- /scripts/recreate_all_schema_errors.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | # Fail on first error, on undefined variables, and on failures in pipelines. 4 | set -euo pipefail 5 | 6 | # Move relative to the top of the repo, so this script can be run from anywhere. 7 | cd "$(git rev-parse --show-toplevel)/trustfall_testbin" 8 | 9 | find ../trustfall_core/test_data/tests/schema_errors -name '*.graphql.ron' | \ 10 | xargs -n 1 \ 11 | sh -c 'cargo run schema_error $0 >"$(dirname $0)/$(basename $0 | cut -d'.' -f1).schema-error.ron"' 12 | -------------------------------------------------------------------------------- /scripts/recreate_all_traces.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | # Fail on first error, on undefined variables, and on failures in pipelines. 4 | set -euo pipefail 5 | 6 | # Move relative to the top of the repo, so this script can be run from anywhere. 7 | cd "$(git rev-parse --show-toplevel)/trustfall_testbin" 8 | 9 | find ../trustfall_core/test_data/tests/valid_queries -name '*.ir.ron' | \ 10 | xargs -n 1 \ 11 | sh -c 'cargo run trace $0 >"$(dirname $0)/$(basename $0 | cut -d'.' -f1).trace.ron"' 12 | -------------------------------------------------------------------------------- /trustfall/LICENSE.txt: -------------------------------------------------------------------------------- 1 | ../LICENSE.txt -------------------------------------------------------------------------------- /trustfall/examples/feeds/example_queries/feed_content.ron: -------------------------------------------------------------------------------- 1 | InputQuery ( 2 | query: r#" 3 | { 4 | Feed { 5 | title { 6 | feed_name: content @output 7 | } 8 | 9 | entry_: entries { 10 | id @output 11 | source @output 12 | 13 | title_: title { 14 | content @output 15 | content_type @output 16 | } 17 | } 18 | } 19 | }"#, 20 | args: {}, 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall/examples/feeds/example_queries/feed_links.ron: -------------------------------------------------------------------------------- 1 | InputQuery ( 2 | query: r#" 3 | { 4 | Feed { 5 | id @output 6 | feed_type @output 7 | 8 | title_: title { 9 | content @output 10 | content_type @output 11 | } 12 | 13 | entries @fold { 14 | title { 15 | entry_title: content @output 16 | } 17 | links { 18 | entry_link: href @output 19 | } 20 | } 21 | } 22 | }"#, 23 | args: {}, 24 | ) 25 | -------------------------------------------------------------------------------- /trustfall/examples/hackernews/example_queries/front_page_stories_with_links.ron: -------------------------------------------------------------------------------- 1 | InputQuery ( 2 | query: r#" 3 | { 4 | FrontPage { 5 | ... on Story { 6 | title @output 7 | submittedUrl @filter(op: "is_not_null") @output 8 | score @output 9 | 10 | byUser { 11 | submitter: id @output 12 | submitter_karma: karma @output 13 | } 14 | } 15 | } 16 | }"#, 17 | args: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall/examples/hackernews/example_queries/jobs_in_top_50.ron: -------------------------------------------------------------------------------- 1 | InputQuery ( 2 | query: r#" 3 | { 4 | Top(max: 50) { 5 | ... on Job { 6 | title @output 7 | url @output 8 | score @output 9 | } 10 | } 11 | }"#, 12 | args: {}, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall/examples/hackernews/example_queries/latest_links_by_high_karma_users.ron: -------------------------------------------------------------------------------- 1 | InputQuery ( 2 | query: r#" 3 | { 4 | Latest(max: 100) { 5 | title @output 6 | submittedUrl @filter(op: "is_not_null") @output 7 | score @output 8 | 9 | byUser { 10 | submitter: id @output 11 | submitter_karma: karma @filter(op: ">=", value: ["$min_karma"]) @output 12 | } 13 | } 14 | }"#, 15 | args: { 16 | "min_karma": Uint64(10000), 17 | }, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall/examples/weather/example_queries/boston_weather.ron: -------------------------------------------------------------------------------- 1 | InputQuery ( 2 | query: r#" 3 | { 4 | LatestMetarReportForAirport(airport_code: "KBOS") { 5 | wind_speed_kts @output 6 | wind_direction @output 7 | wind_gusts_kts @output 8 | temperature @output 9 | dewpoint @output 10 | 11 | cloud_cover @fold { 12 | sky_cover @output 13 | base_altitude @output 14 | } 15 | } 16 | }"#, 17 | args: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/LICENSE.txt: -------------------------------------------------------------------------------- 1 | ../LICENSE.txt -------------------------------------------------------------------------------- /trustfall_core/fuzz/.gitignore: -------------------------------------------------------------------------------- 1 | target 2 | corpus 3 | artifacts 4 | -------------------------------------------------------------------------------- /trustfall_core/src/graphql_query/mod.rs: -------------------------------------------------------------------------------- 1 | //! Parsing Trustfall queries into Rust types, 2 | //! which are then handed to the frontend for further processing. 3 | pub(crate) mod directives; 4 | pub mod error; 5 | pub(crate) mod query; 6 | 7 | // Test-only uses. `#[doc(hidden)]` items are not part of public API 8 | // and are not subject to semantic versioning rules. 9 | #[cfg(feature = "__private")] 10 | #[doc(hidden)] 11 | pub use query::parse_document; 12 | -------------------------------------------------------------------------------- /trustfall_core/src/interpreter/hints/sealed.rs: -------------------------------------------------------------------------------- 1 | pub trait __Sealed {} 2 | -------------------------------------------------------------------------------- /trustfall_core/src/ir/types/mod.rs: -------------------------------------------------------------------------------- 1 | mod base; 2 | mod named_typed; 3 | 4 | pub use base::Type; 5 | pub use named_typed::NamedTypedValue; 6 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/both_missing_and_unused.exec-error.ron: -------------------------------------------------------------------------------- 1 | MultipleErrors(DisplayVec([ 2 | MissingArguments([ 3 | "substr", 4 | ]), 5 | UnusedArguments([ 6 | "unused", 7 | ]), 8 | ])) 9 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/both_missing_and_unused.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | name @filter(op: "has_substring", value: ["$substr"]) 7 | value @output 8 | } 9 | }"#, 10 | arguments: { 11 | "unused": Int64(42), 12 | }, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/invalid_argument_types.exec-error.ron: -------------------------------------------------------------------------------- 1 | MultipleErrors(DisplayVec([ 2 | ArgumentTypeError("num", "Int", String("four")), 3 | ArgumentTypeError("substr", "String!", Int64(4)), 4 | ])) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/invalid_argument_types.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | name @filter(op: "has_substring", value: ["$substr"]) 7 | value @output @filter(op: "=", value: ["$num"]) 8 | } 9 | }"#, 10 | arguments: { 11 | "substr": Int64(4), 12 | "num": String("four"), 13 | }, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/invalid_null_argument_values.exec-error.ron: -------------------------------------------------------------------------------- 1 | MultipleErrors(DisplayVec([ 2 | ArgumentTypeError("numbers", "[Int]!", Null), 3 | ArgumentTypeError("substr", "String!", Null), 4 | ])) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/invalid_null_argument_values.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | name @filter(op: "has_substring", value: ["$substr"]) 7 | value @output @filter(op: "one_of", value: ["$numbers"]) 8 | } 9 | }"#, 10 | arguments: { 11 | "substr": Null, 12 | "numbers": Null, 13 | }, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/missing_argument.exec-error.ron: -------------------------------------------------------------------------------- 1 | MissingArguments([ 2 | "substr", 3 | ]) 4 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/missing_argument.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | name @filter(op: "has_substring", value: ["$substr"]) 7 | value @output 8 | } 9 | }"#, 10 | arguments: {}, 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/missing_unused_and_invalid_arguments.exec-error.ron: -------------------------------------------------------------------------------- 1 | MultipleErrors(DisplayVec([ 2 | ArgumentTypeError("num", "Int", String("four")), 3 | ArgumentTypeError("substr", "String!", Int64(4)), 4 | MissingArguments([ 5 | "max", 6 | ]), 7 | UnusedArguments([ 8 | "min", 9 | ]), 10 | ])) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/missing_unused_and_invalid_arguments.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | name @filter(op: "has_substring", value: ["$substr"]) 7 | value @output @filter(op: "=", value: ["$num"]) @filter(op: "<", value: ["$max"]) 8 | } 9 | }"#, 10 | arguments: { 11 | "substr": Int64(4), 12 | "num": String("four"), 13 | "min": Int64(0), 14 | }, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/type_narrowing_prevents_list_with_null_argument.exec-error.ron: -------------------------------------------------------------------------------- 1 | ArgumentTypeError("arg", "[Int!]!", List([ 2 | Int64(1), 3 | Null, 4 | ])) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/type_narrowing_prevents_null_argument.exec-error.ron: -------------------------------------------------------------------------------- 1 | ArgumentTypeError("arg", "[Int!]!", Null) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/unused_argument.exec-error.ron: -------------------------------------------------------------------------------- 1 | UnusedArguments([ 2 | "unused", 3 | ]) 4 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/execution_errors/unused_argument.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | name @output 7 | value @output 8 | } 9 | }"#, 10 | arguments: { 11 | "unused": Int64(42) 12 | }, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/coercion_of_non_interface.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(ValidationError(CannotCoerceNonInterfaceType("Prime", "Composite"))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/coercion_of_non_interface.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | ... on Composite { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/coercion_to_nonexistent_type.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(ValidationError(NonExistentType("NonExistent"))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/coercion_to_nonexistent_type.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | One { 6 | ... on NonExistent { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/coercion_to_unrelated_type.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(ValidationError(CannotCoerceToUnrelatedType("Number", "Letter"))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/coercion_to_unrelated_type.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | One { 6 | ... on Letter { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_field_with_output.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleOutputsWithSameName(DuplicatedNamesConflict( 2 | duplicates: { 3 | "name": [ 4 | ("Directory", "name"), 5 | ("Directory", "name"), 6 | ], 7 | }, 8 | ))) 9 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_field_with_output.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output 7 | name @output 8 | } 9 | }"#, 10 | arguments: {}, 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleOutputsWithSameName(DuplicatedNamesConflict( 2 | duplicates: { 3 | "name": [ 4 | ("Directory", "name"), 5 | ("Directory", "name"), 6 | ], 7 | }, 8 | ))) 9 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output_from_different_vertices.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleOutputsWithSameName(DuplicatedNamesConflict( 2 | duplicates: { 3 | "name": [ 4 | ("Directory", "name"), 5 | ("File", "name"), 6 | ], 7 | }, 8 | ))) 9 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output_from_different_vertices.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output 7 | 8 | out_Directory_ContainsFile { 9 | name @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output_from_parallel_components.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleOutputsWithSameName(DuplicatedNamesConflict( 2 | duplicates: { 3 | "file_name": [ 4 | ("File", "name"), 5 | ("File", "name"), 6 | ], 7 | }, 8 | ))) 9 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output_from_parallel_components.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | out_Directory_Subdirectory @fold { 7 | file_: out_Directory_ContainsFile { 8 | name @output 9 | } 10 | } 11 | 12 | out_Directory_ContainsFile @fold { 13 | name @output(name: "file_name") 14 | } 15 | } 16 | }"#, 17 | arguments: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output_from_prefix.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleOutputsWithSameName(DuplicatedNamesConflict( 2 | duplicates: { 3 | "dir_name": [ 4 | ("Directory", "name"), 5 | ("Directory", "name"), 6 | ], 7 | }, 8 | ))) 9 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output_from_prefix.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | dir_name: name @output 7 | 8 | dir_: out_Directory_Subdirectory { 9 | name @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output_from_subcomponent.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleOutputsWithSameName(DuplicatedNamesConflict( 2 | duplicates: { 3 | "file_name": [ 4 | ("File", "name"), 5 | ("File", "name"), 6 | ], 7 | }, 8 | ))) 9 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output_from_subcomponent.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | out_Directory_Subdirectory { 7 | file_: out_Directory_ContainsFile { 8 | name @output 9 | } 10 | } 11 | 12 | out_Directory_ContainsFile @fold { 13 | name @output(name: "file_name") 14 | } 15 | } 16 | }"#, 17 | arguments: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output_implicit_and_explicit_fold_count_name.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleOutputsWithSameName(DuplicatedNamesConflict( 2 | duplicates: { 3 | "primeFactorcount": [ 4 | ("primeFactor", "@fold.count"), 5 | ("primeFactor", "@fold.count"), 6 | ], 7 | }, 8 | ))) 9 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output_implicit_and_explicit_fold_count_name.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Four { 6 | primeFactor @fold @transform(op: "count") @output @output(name: "primeFactorcount") { 7 | factors: value @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output_implicit_fold_count_names.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleOutputsWithSameName(DuplicatedNamesConflict( 2 | duplicates: { 3 | "primeFactorcount": [ 4 | ("primeFactor", "@fold.count"), 5 | ("primeFactor", "@fold.count"), 6 | ], 7 | }, 8 | ))) 9 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_output_implicit_fold_count_names.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Four { 6 | primeFactor @fold @transform(op: "count") @output @output { 7 | factors: value @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_tag.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleTagsWithSameName("tagged")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_tag.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @tag(name: "tagged") 7 | 8 | out_Directory_ContainsFile { 9 | name @tag(name: "tagged") 10 | } 11 | 12 | out_Directory_ContainsFile { 13 | name @output @filter(op: "has_substring", value: ["%tagged"]) 14 | } 15 | } 16 | }"#, 17 | arguments: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_tag_across_fold.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleTagsWithSameName("tagged")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_tag_across_fold.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | One { 6 | value @tag(name: "tagged") 7 | 8 | successor @fold { 9 | value @tag(name: "tagged") 10 | 11 | successor { 12 | value @output @filter(op: ">", value: ["%tagged"]) 13 | } 14 | } 15 | } 16 | }"#, 17 | arguments: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_tag_in_nested_fold.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleTagsWithSameName("tagged")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_tag_in_separate_folds.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleErrors(DisplayVec([ 2 | MultipleTagsWithSameName("tagged"), 3 | TagUsedOutsideItsFoldedSubquery("value", "tagged"), 4 | ]))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/duplicate_tag_with_parent_after_fold.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleErrors(DisplayVec([ 2 | MultipleTagsWithSameName("tagged"), 3 | TagUsedOutsideItsFoldedSubquery("value", "tagged"), 4 | ]))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/explicit_null_in_non_nullable_edge_parameter.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(InvalidEdgeParameterType("max", "Number", "Int!", Null)) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/explicit_null_in_non_nullable_edge_parameter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: null) { 6 | value @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_contains_on_non_container.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(ListFilterOperationOnNonListSubject("contains", "property \"integer\" of type \"Int\""))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_contains_on_non_container.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | nonNullInteger @output @tag(name: "my_tag") 7 | 8 | integer @filter(op: "contains", value: ["%my_tag"]) 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_contains_with_uncontainable_type.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(TypeMismatchBetweenFilterSubjectAndArgument("contains", "property \"intList\" of type \"[Int]\"", "tag \"my_tag\" of type \"String\""))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_contains_with_uncontainable_type.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | string @output @tag(name: "my_tag") 7 | 8 | intList @filter(op: "contains", value: ["%my_tag"]) 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_directive_on_edge.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedEdgeFilter("out_Directory_Subdirectory")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_directive_on_edge.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | out_Directory_Subdirectory @filter(op: "is_null") { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_directive_on_edge_bare.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedEdgeFilter("out_Directory_Subdirectory")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_directive_on_edge_bare.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output 7 | 8 | out_Directory_Subdirectory @filter(op: "is_null") 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_non_null_field_for_null.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(NonNullableTypeFilteredForNullability("is_null", "property \"nonNullString\" of type \"String!\"", false))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_non_null_field_for_null.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | nonNullString @filter(op: "is_null") @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_non_nullable_field_for_non_null.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(NonNullableTypeFilteredForNullability("is_not_null", "property \"nonNullString\" of type \"String!\"", true))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_non_nullable_field_for_non_null.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | nonNullString @filter(op: "is_not_null") @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_non_orderable_types.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleErrors(DisplayVec([ 2 | FilterTypeError(OrderingFilterOperationOnNonOrderableSubject("<", "property \"bool\" of type \"Boolean\"")), 3 | FilterTypeError(OrderingFilterOperationWithNonOrderableArgument("<", "tag \"my_tag\" of type \"Boolean!\"")), 4 | ]))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_non_orderable_types.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | nonNullBool @output @tag(name: "my_tag") 7 | 8 | bool @filter(op: "<", value: ["%my_tag"]) 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_one_of_on_uncontainable_type.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(TypeMismatchBetweenFilterSubjectAndArgument("one_of", "property \"string\" of type \"String\"", "tag \"my_tag\" of type \"[Int]\""))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_one_of_on_uncontainable_type.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | intList @output @tag(name: "my_tag") 7 | 8 | string @filter(op: "one_of", value: ["%my_tag"]) 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_one_of_with_non_container_type.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(ListFilterOperationOnNonListArgument("one_of", "tag \"my_tag\" of type \"Int\""))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_one_of_with_non_container_type.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | integer @output @tag(name: "my_tag") 7 | 8 | string @filter(op: "one_of", value: ["%my_tag"]) 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_orderable_type_mismatch.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleErrors(DisplayVec([ 2 | FilterTypeError(OrderingFilterOperationWithNonOrderableArgument(">=", "tag \"my_tag\" of type \"Boolean!\"")), 3 | FilterTypeError(TypeMismatchBetweenFilterSubjectAndArgument(">=", "property \"integer\" of type \"Int\"", "tag \"my_tag\" of type \"Boolean!\"")), 4 | ]))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_orderable_type_mismatch.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | nonNullBool @output @tag(name: "my_tag") 7 | 8 | integer @filter(op: ">=", value: ["%my_tag"]) 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_regex_on_non_strings.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleErrors(DisplayVec([ 2 | FilterTypeError(StringFilterOperationOnNonStringSubject("regex", "property \"bool\" of type \"Boolean\"")), 3 | FilterTypeError(StringFilterOperationOnNonStringArgument("regex", "tag \"my_tag\" of type \"Int\"")), 4 | ]))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_regex_on_non_strings.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | integer @output @tag(name: "my_tag") 7 | 8 | bool @filter(op: "regex", value: ["%my_tag"]) 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_tag_type_mismatch_both_non_nullable.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(TypeMismatchBetweenFilterSubjectAndArgument("=", "property \"nonNullString\" of type \"String!\"", "tag \"my_tag\" of type \"Int!\""))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_tag_type_mismatch_both_non_nullable.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | nonNullInteger @tag(name: "my_tag") @output 7 | 8 | nonNullString @filter(op: "=", value: ["%my_tag"]) 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_tag_type_mismatch_both_nullable.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(TypeMismatchBetweenFilterSubjectAndArgument("=", "property \"string\" of type \"String\"", "tag \"my_tag\" of type \"Int\""))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_tag_type_mismatch_both_nullable.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | integer @tag(name: "my_tag") @output 7 | 8 | string @filter(op: "=", value: ["%my_tag"]) 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_tag_type_mismatch_field_non_nullable.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(TypeMismatchBetweenFilterSubjectAndArgument("=", "property \"nonNullString\" of type \"String!\"", "tag \"my_tag\" of type \"Int\""))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_tag_type_mismatch_field_non_nullable.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | integer @tag(name: "my_tag") @output 7 | 8 | nonNullString @filter(op: "=", value: ["%my_tag"]) 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_tag_type_mismatch_tag_non_nullable.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(TypeMismatchBetweenFilterSubjectAndArgument("=", "property \"string\" of type \"String\"", "tag \"my_tag\" of type \"Int!\""))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/filter_tag_type_mismatch_tag_non_nullable.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | nonNullInteger @tag(name: "my_tag") @output 7 | 8 | string @filter(op: "=", value: ["%my_tag"]) 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/fold_and_transform_used_on_property.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDirectiveOnProperty("@fold", "vowelsInName")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/fold_and_transform_used_on_property.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | value @output 7 | vowelsInName @fold @transform(op: "count") 8 | } 9 | }"#, 10 | arguments: {}, 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/fold_count_tag_value_used_inside_own_fold.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UndefinedTagInFilter("value", "tagged_count")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/fold_count_tag_value_used_inside_own_fold.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | successor @fold @transform(op: "count") @tag(name: "tagged_count") { 7 | value @filter(op: "=", value: ["%tagged_count"]) @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/fold_used_on_property.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDirectiveOnProperty("@fold", "vowelsInName")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/fold_used_on_property.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | value @output 7 | vowelsInName @fold 8 | } 9 | }"#, 10 | arguments: {}, 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/implicit_tag_name_on_transformed_value.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleErrors(DisplayVec([ 2 | ExplicitTagNameRequired("successor"), 3 | UndefinedTagInFilter("value", "successorcount"), 4 | ]))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/implicit_tag_name_on_transformed_value.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | successor @fold @transform(op: "count") @tag 7 | 8 | predecessor { 9 | value @filter(op: "=", value: ["%successorcount"]) @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/incompatible_list_inferred_variable_types.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(IncompatibleVariableTypeRequirements("arg", "[Int]!", "[String!]!"))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/incompatible_list_inferred_variable_types.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | integer @output @filter(op: "one_of", value: ["$arg"]) 7 | nonNullString @filter(op: "one_of", value: ["$arg"]) 8 | } 9 | }"#, 10 | arguments: { 11 | "arg": Null 12 | }, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/incompatible_list_vs_nested_list_variable_types.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(IncompatibleVariableTypeRequirements("arg", "[Int!]!", "[[Int!]!]!"))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/incompatible_list_vs_nested_list_variable_types.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | nonNullInteger @output @filter(op: "one_of", value: ["$arg"]) 7 | nonNullIntAndList @filter(op: "one_of", value: ["$arg"]) 8 | } 9 | }"#, 10 | arguments: { 11 | "arg": Null 12 | }, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/incompatible_scalar_inferred_variable_types.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(IncompatibleVariableTypeRequirements("arg", "Int", "String!"))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/incompatible_scalar_inferred_variable_types.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | integer @output @filter(op: "=", value: ["$arg"]) 7 | nonNullString @filter(op: "=", value: ["$arg"]) 8 | } 9 | }"#, 10 | arguments: { 11 | "arg": Null 12 | }, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/incompatible_scalar_vs_list_inferred_variable_types.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(IncompatibleVariableTypeRequirements("arg", "[Int]!", "String!"))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/incompatible_scalar_vs_list_inferred_variable_types.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "nullables", 3 | query: r#" 4 | { 5 | MainType { 6 | integer @output @filter(op: "one_of", value: ["$arg"]) 7 | nonNullString @filter(op: "=", value: ["$arg"]) 8 | } 9 | }"#, 10 | arguments: { 11 | "arg": Null 12 | }, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/incorrect_edge_parameter_type.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleErrors(DisplayVec([ 2 | InvalidEdgeParameterType("max", "Number", "Int!", String("foo")), 3 | InvalidEdgeParameterType("max", "multiple", "Int!", Float64(12.34)), 4 | ]))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/incorrect_edge_parameter_type.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: "foo") { 6 | value @output 7 | 8 | multiple(max: 12.34) { 9 | mult: value @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/missing_multiple_required_edge_parameters.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleErrors(DisplayVec([ 2 | MissingRequiredEdgeParameter("max", "Number"), 3 | MissingRequiredEdgeParameter("max", "multiple"), 4 | ]))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/missing_multiple_required_edge_parameters.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 5) { 6 | value @output 7 | 8 | multiple { 9 | mult: value @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/missing_required_edge_parameter.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MissingRequiredEdgeParameter("max", "Number")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/missing_required_edge_parameter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number { 6 | value @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/multiple_fold_output_errors.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleErrors(DisplayVec([ 2 | UnsupportedEdgeOutput("primeFactor"), 3 | MultipleOutputsWithSameName(DuplicatedNamesConflict( 4 | duplicates: { 5 | "primeFactorcount": [ 6 | ("primeFactor", "@fold.count"), 7 | ("primeFactor", "@fold.count"), 8 | ], 9 | }, 10 | )), 11 | ]))) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/multiple_fold_output_errors.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Four { 6 | primeFactor @output @fold @transform(op: "count") @output @output(name: "primeFactorcount") { 7 | factors: value @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/non_existent_bare_root.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(ValidationError(NonExistentPath([ 2 | "NonExistent", 3 | ]))) 4 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/non_existent_bare_root.graphql-parsed.ron: -------------------------------------------------------------------------------- 1 | Ok(TestParsedGraphQLQuery( 2 | schema_name: "filesystem", 3 | query: Query( 4 | root_connection: FieldConnection( 5 | position: Pos( 6 | line: 3, 7 | column: 5, 8 | ), 9 | name: "NonExistent", 10 | ), 11 | root_field: FieldNode( 12 | position: Pos( 13 | line: 3, 14 | column: 5, 15 | ), 16 | name: "NonExistent", 17 | ), 18 | ), 19 | )) 20 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/non_existent_bare_root.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | NonExistent 6 | }"#, 7 | arguments: {}, 8 | ) 9 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/non_existent_child.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(ValidationError(NonExistentPath([ 2 | "OriginDirectory", 3 | "NonExistent", 4 | ]))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/non_existent_child.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | NonExistent { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/non_existent_expanded_root.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(ValidationError(NonExistentPath([ 2 | "NonExistent", 3 | ]))) 4 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/non_existent_expanded_root.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | NonExistent { 6 | child 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/optional_and_fold.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDirectiveOnFoldedEdge("out_Directory_ContainsFile", "@optional")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/optional_and_fold.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | out_Directory_ContainsFile @optional @fold { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/optional_used_on_property.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDirectiveOnProperty("@optional", "vowelsInName")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/optional_used_on_property.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | value @output 7 | vowelsInName @optional 8 | } 9 | }"#, 10 | arguments: {}, 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/output_directive_on_edge.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedEdgeOutput("out_Directory_Subdirectory")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/output_directive_on_edge.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | out_Directory_Subdirectory @output { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/output_directive_on_edge_bare.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedEdgeOutput("out_Directory_Subdirectory")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/output_directive_on_edge_bare.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output 7 | out_Directory_Subdirectory @output 8 | } 9 | }"#, 10 | arguments: {}, 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recurse_and_fold.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDirectiveOnFoldedEdge("out_Directory_Subdirectory", "@recurse")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recurse_and_fold.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | out_Directory_Subdirectory @recurse(depth: 2) @fold { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recurse_on_same_name_edge_of_unrelated_type.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(RecursingNonRecursableEdge("cyclic", "FinalDerived", "Unrelated")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recurse_on_same_name_edge_of_unrelated_type.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "recurses", 3 | query: r#" 4 | { 5 | FinalDerived { 6 | field @output 7 | 8 | cyclic @recurse(depth: 3) { 9 | deeper: field @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recurse_used_on_property.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDirectiveOnProperty("@recurse", "vowelsInName")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recurse_used_on_property.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | value @output 7 | vowelsInName @recurse(depth: 3) 8 | } 9 | }"#, 10 | arguments: {}, 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recursion_needing_multiple_implicit_coercions.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(EdgeRecursionNeedingMultipleCoercions("firstEdge")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recursion_needing_multiple_implicit_coercions.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "recurses", 3 | query: r#" 4 | { 5 | DeeperDerived { 6 | field @output 7 | 8 | firstEdge @recurse(depth: 3) { 9 | deeper: field @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recursion_needing_multiple_implicit_coercions_based_on_origin.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(EdgeRecursionNeedingMultipleCoercions("secondEdge")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recursion_needing_multiple_implicit_coercions_based_on_origin.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "recurses", 3 | query: r#" 4 | { 5 | FinalDerived { 6 | field @output 7 | 8 | secondEdge @recurse(depth: 3) { 9 | deeper: field @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recursion_on_non_recursable_edge.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(RecursingNonRecursableEdge("primeFactor", "Composite", "Prime")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recursion_on_non_recursable_edge.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | ... on Composite { 7 | value @output 8 | 9 | primeFactor @recurse(depth: 3) { 10 | inner: value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recursion_to_subtype.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(RecursionToSubtype("multiple", "Number", "Composite")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/recursion_to_subtype.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | value @output 7 | 8 | multiple(max: 2) @recurse(depth: 2) { 9 | mult: value @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/tag_and_filter_in_unrelated_folds.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(TagUsedOutsideItsFoldedSubquery("value", "folded")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/tag_before_filter_in_different_scopes.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(TagUsedBeforeDefinition("name", "my_tag")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/tag_from_inside_fold.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(TagUsedOutsideItsFoldedSubquery("value", "folded")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/tag_on_an_edge.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedEdgeTag("successor")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/tag_on_an_edge.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | // This query should fail to parse due to using `@tag` 3 | // on an edge, as `@tag` is only valid on properties. 4 | schema_name: "numbers", 5 | query: r#" 6 | { 7 | Four { 8 | value @output 9 | successor @tag(name: "five") 10 | } 11 | }"#, 12 | arguments: {}, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/tag_used_in_fold_but_defined_after.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UndefinedTagInFilter("value", "my_tag")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/typename_as_edge.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(PropertyMetaFieldUsedAsEdge("__typename")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/typename_as_edge.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | One { 6 | __typename { 7 | foo @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/typename_is_not_null.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterTypeError(NonNullableTypeFilteredForNullability("is_not_null", "property \"__typename\" of type \"String!\"", true))) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/typename_is_not_null.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | One { 6 | __typename @filter(op: "is_not_null") @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/undefined_tag.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UndefinedTagInFilter("name", "undefined_tag_name")) 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/undefined_tag.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output @filter(op: "=", value: ["%undefined_tag_name"]) 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/unexpected_edge_parameters.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleErrors(DisplayVec([ 2 | UnexpectedEdgeParameter("nonexistent", "Number"), 3 | UnexpectedEdgeParameter("other", "multiple"), 4 | ]))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/unexpected_edge_parameters.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10, nonexistent: "foo") { 6 | value @output 7 | 8 | multiple(max: 2, other: 3.14) { 9 | mult: value @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/unused_tag.frontend-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnusedTags([ 2 | "name", 3 | ])) 4 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/frontend_errors/unused_tag.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | 4 | // The @tag is unused, so this is an error. 5 | query: r#" 6 | { 7 | Four { 8 | name @tag 9 | value @output 10 | } 11 | }"#, 12 | arguments: {}, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/coercion_with_sibling_fields.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | value @output 7 | 8 | successor { 9 | succ: name @output 10 | ... on Prime { 11 | prime: value @output 12 | } 13 | } 14 | } 15 | }"#, 16 | arguments: {}, 17 | ) 18 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/coercion_with_sibling_fields.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(TypeCoercionWithSiblingFields(Pos( 2 | line: 8, 3 | column: 13, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/directive_before_root.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | query @output { 5 | Number(max: 5) { 6 | value @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/directive_before_root.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(DirectiveNotInsideQueryRoot("output", Pos( 2 | line: 2, 3 | column: 7, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/directive_on_root.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 5) @output { 6 | value @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/directive_on_root.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(DirectiveNotInsideQueryRoot("output", Pos( 2 | line: 3, 3 | column: 20, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/duplicate_edge_parameter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 5, max: 10) { 6 | value @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/duplicate_edge_parameter.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(DuplicatedEdgeParameter("max", "Number", Pos( 2 | line: 3, 3 | column: 25, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/duplicate_fold.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output 7 | 8 | out_Directory_ContainsFile @fold @fold { 9 | file: name @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/duplicate_fold.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDuplicatedDirective("@fold", Pos( 2 | line: 6, 3 | column: 42, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/duplicate_optional.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output 7 | 8 | out_Directory_ContainsFile @optional @optional { 9 | file: name @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/duplicate_optional.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDuplicatedDirective("@optional", Pos( 2 | line: 6, 3 | column: 46, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/duplicate_recurse.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | out_Directory_Subdirectory @recurse(depth: 2) @recurse(depth: 3) { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/duplicate_recurse.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDuplicatedDirective("@recurse", Pos( 2 | line: 4, 3 | column: 55, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/filter_with_tag_string_instead_of_array_with_tag_string.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterExpectsListNotString("=", "%zerovalue", Pos( 2 | line: 5, 3 | column: 39, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/filter_with_value_of_just_dollar_sign.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | // Purposefully use a string of just '$' to ensure that we handle that. 3 | schema_name: "numbers", 4 | query: r#" 5 | { 6 | Zero { 7 | value @filter(op: "=", value: ["$"]) 8 | } 9 | }"#, 10 | arguments: {}, 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/filter_with_value_of_just_dollar_sign.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(InvalidFilterOperandName("$", "Filter argument is empty after \'$\' prefix.", Pos( 2 | line: 4, 3 | column: 39, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/filter_with_value_of_just_percent_sign.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | // Purposefully use a string of just '%' to ensure that we handle that. 3 | schema_name: "numbers", 4 | query: r#" 5 | { 6 | Zero { 7 | value @filter(op: "=", value: ["%"]) 8 | } 9 | }"#, 10 | arguments: {}, 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/filter_with_value_of_just_percent_sign.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(InvalidFilterOperandName("%", "Filter argument is empty after \'%\' prefix.", Pos( 2 | line: 4, 3 | column: 39, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/filter_with_variable_string_instead_of_array_with_variable_string.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(FilterExpectsListNotString("=", "$zero", Pos( 2 | line: 4, 3 | column: 39, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/fold_and_optional.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | out_Directory_ContainsFile @fold @optional { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/fold_and_optional.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDirectivePosition("@optional", "this directive cannot appear after a @fold directive", Pos( 2 | line: 4, 3 | column: 42, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/fold_and_output.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | out_Directory_ContainsFile @fold @output { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/fold_and_output.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDirectivePosition("@output", "this directive cannot appear after a @fold directive", Pos( 2 | line: 4, 3 | column: 42, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/fold_and_recurse.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | out_Directory_Subdirectory @fold @recurse(depth: 2) { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/fold_and_recurse.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDirectivePosition("@recurse", "this directive cannot appear after a @fold directive", Pos( 2 | line: 4, 3 | column: 42, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/fragment_spread.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 5) { 6 | value @output 7 | 8 | ...foo 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/fragment_spread.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedSyntax("fragment spread", Pos( 2 | line: 6, 3 | column: 9, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/invalid_edge_argument.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: { x: "y" }) { 6 | value @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/invalid_edge_argument.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(InvalidFieldArgument("Number", "max", { 2 | "x": "y", 3 | }, Pos( 4 | line: 3, 5 | column: 17, 6 | ))) 7 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/invalid_filter_argument_name.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output @filter(op: "has_substring", value: ["$containsåäö"]) 7 | } 8 | }"#, 9 | arguments: { 10 | "containsåäö": String("src") 11 | } 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/invalid_filter_argument_name.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(InvalidFilterOperandName("$containsåäö", "Filter argument names must only contain ASCII alphanumerics or underscore characters: containsåäö", Pos( 2 | line: 4, 3 | column: 58, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/invalid_filter_argument_name_start.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output @filter(op: "has_substring", value: ["$1forexample"]) 7 | } 8 | }"#, 9 | arguments: { 10 | "1forexample": String("src") 11 | } 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/invalid_filter_argument_name_start.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(InvalidFilterOperandName("$1forexample", "Filter argument names must start with an ASCII letter or underscore character: 1forexample", Pos( 2 | line: 4, 3 | column: 58, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/invalid_filter_op.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output @filter(op: "non_existent", value: ["$dir_name"]) 7 | } 8 | }"#, 9 | arguments: { 10 | "dir_name": String("") 11 | }, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/invalid_filter_op.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedFilterOperator("non_existent", Pos( 2 | line: 4, 3 | column: 34, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/invalid_fold_transform_op.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | multiple(max: 3) @fold @transform(op: "non_existent") @output { 7 | value @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/invalid_fold_transform_op.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedTransformOperator("non_existent", Pos( 2 | line: 4, 3 | column: 47, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/multiple_roots.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 3) { 6 | num: value @output 7 | } 8 | Number(max: 4) { 9 | value @output 10 | } 11 | }"#, 12 | arguments: {}, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/multiple_roots.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(MultipleQueryRoots(Pos( 2 | line: 6, 3 | column: 5, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/nested_type_coercion.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | value @output 7 | 8 | successor { 9 | ... on Prime { 10 | ... on Number { 11 | prime: value @output 12 | } 13 | } 14 | } 15 | } 16 | }"#, 17 | arguments: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/nested_type_coercion.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(NestedTypeCoercion(Pos( 2 | line: 8, 3 | column: 17, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/output_name_with_dashes.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output(name: "name-with-dashes") 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/output_name_with_dashes.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(InvalidOutputName("name-with-dashes", [ 2 | '-', 3 | ], Pos( 4 | line: 4, 5 | column: 28, 6 | ))) 7 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/output_name_with_multiple_invalid_chars.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output(name: "name with-various $%^&# chars!") 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/output_name_with_multiple_invalid_chars.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(InvalidOutputName("name with-various $%^&# chars!", [ 2 | ' ', 3 | '-', 4 | '$', 5 | '%', 6 | '^', 7 | '&', 8 | '#', 9 | '!', 10 | ], Pos( 11 | line: 4, 12 | column: 28, 13 | ))) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/output_name_with_spaces.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @output(name: "name with spaces") 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/output_name_with_spaces.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(InvalidOutputName("name with spaces", [ 2 | ' ', 3 | ], Pos( 4 | line: 4, 5 | column: 28, 6 | ))) 7 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/tag_name_with_multiple_invalid_chars.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | name @tag(name: "name with-various $%^&# chars!") @output 7 | 8 | out_Directory_ContainsFile { 9 | name @filter(op: "has_substring", value: ["%name with-various $%^&# chars!"]) 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/tag_name_with_multiple_invalid_chars.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(InvalidTagName("name with-various $%^&# chars!", [ 2 | ' ', 3 | '-', 4 | '$', 5 | '%', 6 | '^', 7 | '&', 8 | '#', 9 | '!', 10 | ], Pos( 11 | line: 4, 12 | column: 25, 13 | ))) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/tag_on_fold.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | // This test ensures that an `@fold` after an `@tag` is a parse error. 3 | schema_name: "numbers", 4 | query: r#" 5 | { 6 | Number(max: 5) { 7 | value @output 8 | 9 | primeFactor @fold @tag { 10 | value @output 11 | } 12 | } 13 | }"#, 14 | arguments: {}, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/tag_on_fold.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDirectivePosition("@tag", "this directive cannot appear after a @fold directive", Pos( 2 | line: 6, 3 | column: 27, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/transform_first_directive.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "filesystem", 3 | query: r#" 4 | { 5 | OriginDirectory { 6 | out_Directory_ContainsFile @transform(op: "count") @output { 7 | name @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/transform_first_directive.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnsupportedDirectivePosition("@transform", "Cannot transform an edge prior to a @fold directive. Consider adding @fold before the @transform here.", Pos( 2 | line: 4, 3 | column: 36, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/typo_in_filter_value_argument_name.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnrecognizedDirectiveArgument("@filter", "values", Pos( 2 | line: 4, 3 | column: 40, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/unrecognized_directive.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 5) { 6 | value @unrecognized 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/unrecognized_directive.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(UnrecognizedDirective("unrecognized", Pos( 2 | line: 4, 3 | column: 15, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/variable_in_root_query.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | query FirstQuery($max: Int!) { 5 | Number(max: $max) { 6 | num: value @output 7 | } 8 | } 9 | "#, 10 | arguments: { 11 | "max": Int64(3) 12 | }, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/parse_errors/variable_in_root_query.parse-error.ron: -------------------------------------------------------------------------------- 1 | Err(VariableDefinitionInQuery(Pos( 2 | line: 2, 3 | column: 18, 4 | ))) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/ambiguous_field_origin.schema-error.ron: -------------------------------------------------------------------------------- 1 | AmbiguousFieldOrigin("Derived", "field", "String", [ 2 | "A", 3 | "B", 4 | ]) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/circular_implements_relationship.schema-error.ron: -------------------------------------------------------------------------------- 1 | CircularImplementsRelationships([ 2 | "A", 3 | "B", 4 | ]) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/completely_different_field_type.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidTypeWideningOfInheritedField("integer", "Derived", "Base", "String!", "Int!") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/edge_to_root_query_type.schema-error.ron: -------------------------------------------------------------------------------- 1 | EdgePointsToRootQueryType("Base", "root", "RootSchemaQuery!") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/explicit_null_default_for_non_nullable_edge_param.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidDefaultValueForFieldParameter("RootSchemaQuery", "Vertex", "param", "Int!", "Null") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/implementing_non_existent_type.schema-error.ron: -------------------------------------------------------------------------------- 1 | ImplementingNonExistentType("Derived", "Base") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/implementing_object_type.schema-error.ron: -------------------------------------------------------------------------------- 1 | ImplementingNonInterface("Derived", "Base") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/implementing_self_type.schema-error.ron: -------------------------------------------------------------------------------- 1 | CircularImplementsRelationships([ 2 | "Base", 3 | ]) 4 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/incorrect_default_value_type_for_edge_param.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidDefaultValueForFieldParameter("RootSchemaQuery", "Vertex", "param", "String", "Int64(123)") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/interface_with_same_field_twice.schema-error.ron: -------------------------------------------------------------------------------- 1 | DuplicateFieldDefinition("Apple", "color") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/list_of_list_edge.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidEdgeType("Base", "neighbor", "[[Base]]") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/list_of_list_root_edge.graphql: -------------------------------------------------------------------------------- 1 | schema { 2 | query: RootSchemaQuery 3 | } 4 | directive @filter(op: String!, value: [String!]) repeatable on FIELD | INLINE_FRAGMENT 5 | directive @tag(name: String) on FIELD 6 | directive @output(name: String) on FIELD 7 | directive @optional on FIELD 8 | directive @recurse(depth: Int!) on FIELD 9 | directive @fold on FIELD 10 | directive @transform(op: String!) on FIELD 11 | 12 | type RootSchemaQuery { 13 | Base: [[Base]] 14 | } 15 | 16 | type Base { 17 | field: String 18 | } 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/list_of_list_root_edge.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidEdgeType("RootSchemaQuery", "Base", "[[Base]]") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/missing_field_and_illegal_type_widening.schema-error.ron: -------------------------------------------------------------------------------- 1 | MultipleErrors(DisplayVec([ 2 | InvalidTypeWideningOfInheritedField("foo", "Derived", "Base", "Int", "Int!"), 3 | MissingRequiredField("Derived", "Base", "bar", "String"), 4 | ])) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/missing_required_field.schema-error.ron: -------------------------------------------------------------------------------- 1 | MissingRequiredField("Derived", "Base", "maybeMissing", "String") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/one_type_one_interface_both_same_name.schema-error.ron: -------------------------------------------------------------------------------- 1 | DuplicateTypeOrInterfaceDefinition("Apple") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/parameterized_field_missing_parameter_in_subtype.schema-error.ron: -------------------------------------------------------------------------------- 1 | InheritedFieldMissingParameters("theEdge", "Derived", "Base", [ 2 | "param", 3 | ]) 4 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/parameters_in_property_field.schema-error.ron: -------------------------------------------------------------------------------- 1 | PropertyFieldWithParameters("Base", "field", "String", [ 2 | "firstParam", 3 | "secondParam", 4 | ]) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/property_on_root_query_type.schema-error.ron: -------------------------------------------------------------------------------- 1 | PropertyFieldOnRootQueryType("RootSchemaQuery", "Property", "Int") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/reserved_prefix_edge_defined.schema-error.ron: -------------------------------------------------------------------------------- 1 | ReservedFieldName("Foo", "__bar") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/reserved_prefix_property_defined.schema-error.ron: -------------------------------------------------------------------------------- 1 | ReservedFieldName("Foo", "__typename") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/reserved_prefix_query_type.graphql: -------------------------------------------------------------------------------- 1 | schema { 2 | query: __RootSchemaQuery 3 | } 4 | directive @filter(op: String!, value: [String!]) repeatable on FIELD | INLINE_FRAGMENT 5 | directive @tag(name: String) on FIELD 6 | directive @output(name: String) on FIELD 7 | directive @optional on FIELD 8 | directive @recurse(depth: Int!) on FIELD 9 | directive @fold on FIELD 10 | directive @transform(op: String!) on FIELD 11 | 12 | type __RootSchemaQuery { 13 | Foo: Foo 14 | } 15 | 16 | type Foo { 17 | field: String 18 | } 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/reserved_prefix_query_type.schema-error.ron: -------------------------------------------------------------------------------- 1 | ReservedTypeName("__RootSchemaQuery") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/reserved_prefix_top_level_field.graphql: -------------------------------------------------------------------------------- 1 | schema { 2 | query: RootSchemaQuery 3 | } 4 | directive @filter(op: String!, value: [String!]) repeatable on FIELD | INLINE_FRAGMENT 5 | directive @tag(name: String) on FIELD 6 | directive @output(name: String) on FIELD 7 | directive @optional on FIELD 8 | directive @recurse(depth: Int!) on FIELD 9 | directive @fold on FIELD 10 | directive @transform(op: String!) on FIELD 11 | 12 | type RootSchemaQuery { 13 | __Foo: Foo 14 | } 15 | 16 | type Foo { 17 | field: String 18 | } 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/reserved_prefix_top_level_field.schema-error.ron: -------------------------------------------------------------------------------- 1 | ReservedFieldName("RootSchemaQuery", "__Foo") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/reserved_prefix_type_name.graphql: -------------------------------------------------------------------------------- 1 | schema { 2 | query: RootSchemaQuery 3 | } 4 | directive @filter(op: String!, value: [String!]) repeatable on FIELD | INLINE_FRAGMENT 5 | directive @tag(name: String) on FIELD 6 | directive @output(name: String) on FIELD 7 | directive @optional on FIELD 8 | directive @recurse(depth: Int!) on FIELD 9 | directive @fold on FIELD 10 | directive @transform(op: String!) on FIELD 11 | 12 | type RootSchemaQuery { 13 | Foo: __Foo 14 | } 15 | 16 | type __Foo { 17 | field: String 18 | } 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/reserved_prefix_type_name.schema-error.ron: -------------------------------------------------------------------------------- 1 | ReservedTypeName("__Foo") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/root_edge_to_root_query_type.schema-error.ron: -------------------------------------------------------------------------------- 1 | EdgePointsToRootQueryType("RootSchemaQuery", "Root", "[RootSchemaQuery!]!") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/subtype_adds_parameter_to_field.schema-error.ron: -------------------------------------------------------------------------------- 1 | InheritedFieldUnexpectedParameters("theEdge", "Derived", "Base", [ 2 | "param", 3 | ]) 4 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/transitive_interface_not_implemented.schema-error.ron: -------------------------------------------------------------------------------- 1 | MissingTransitiveInterfaceImplementation("Final", "Sub", "Super") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/triple_list_edge.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidEdgeType("Base", "neighbor", "[[[Base]]]") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/triple_list_root_edge.graphql: -------------------------------------------------------------------------------- 1 | schema { 2 | query: RootSchemaQuery 3 | } 4 | directive @filter(op: String!, value: [String!]) repeatable on FIELD | INLINE_FRAGMENT 5 | directive @tag(name: String) on FIELD 6 | directive @output(name: String) on FIELD 7 | directive @optional on FIELD 8 | directive @recurse(depth: Int!) on FIELD 9 | directive @fold on FIELD 10 | directive @transform(op: String!) on FIELD 11 | 12 | type RootSchemaQuery { 13 | Base: [[[Base]]] 14 | } 15 | 16 | type Base { 17 | field: String 18 | } 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/triple_list_root_edge.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidEdgeType("RootSchemaQuery", "Base", "[[[Base]]]") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/two_interface_same_name.schema-error.ron: -------------------------------------------------------------------------------- 1 | DuplicateTypeOrInterfaceDefinition("Apple") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/two_types_same_name.schema-error.ron: -------------------------------------------------------------------------------- 1 | DuplicateTypeOrInterfaceDefinition("Apple") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/type_narrowing_parameterized_edge.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidTypeNarrowingOfInheritedFieldParameter("theEdge", "Derived", "Base", "param", "Int!", "Int") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/type_narrowing_parameterized_edge_list_param.schema-error.ron: -------------------------------------------------------------------------------- 1 | MultipleErrors(DisplayVec([ 2 | InvalidTypeNarrowingOfInheritedFieldParameter("theEdge", "Derived", "Base", "param", "[Int!]", "[Int]"), 3 | InvalidTypeNarrowingOfInheritedFieldParameter("theSecondEdge", "Derived", "Base", "param", "[Int]!", "[Int]"), 4 | InvalidTypeNarrowingOfInheritedFieldParameter("theThirdEdge", "Derived", "Base", "param", "[Int!]!", "[Int]"), 5 | ])) 6 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/type_widening_edge_supertype.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidTypeWideningOfInheritedField("theEdge", "Derived", "Base", "Base!", "Derived!") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/type_widening_list_edge_supertype.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidTypeWideningOfInheritedField("theEdge", "Derived", "Base", "[Base!]!", "[Derived!]!") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/type_widening_nullability_on_edge_field.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidTypeWideningOfInheritedField("nonNullableEdge", "Derived", "Base", "Other", "Other!") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/type_widening_nullability_on_list_edge_field.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidTypeWideningOfInheritedField("nonNullableEdge", "Derived", "Base", "[Other!]", "[Other!]!") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/type_widening_of_inherited_scalar_field.schema-error.ron: -------------------------------------------------------------------------------- 1 | InvalidTypeWideningOfInheritedField("integer", "Derived", "Base", "Int", "Int!") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/type_with_same_field_twice.schema-error.ron: -------------------------------------------------------------------------------- 1 | DuplicateFieldDefinition("Apple", "color") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/unknown_type_not_on_root.graphql: -------------------------------------------------------------------------------- 1 | schema { 2 | query: Query 3 | } 4 | 5 | type Query { 6 | children: [Child!] 7 | } 8 | 9 | type Child { 10 | unknown: UnknownType 11 | } 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/unknown_type_not_on_root.schema-error.ron: -------------------------------------------------------------------------------- 1 | UnknownPropertyOrEdgeType("unknown", "UnknownType") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/unknown_type_on_root.graphql: -------------------------------------------------------------------------------- 1 | schema { 2 | query: RootSchemaQuery 3 | } 4 | 5 | type RootSchemaQuery { 6 | secret: FakeType! 7 | } 8 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/unknown_type_on_root.schema-error.ron: -------------------------------------------------------------------------------- 1 | UnknownPropertyOrEdgeType("secret", "FakeType!") 2 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/unknown_type_on_root_and_outside.graphql: -------------------------------------------------------------------------------- 1 | schema { 2 | query: Query 3 | } 4 | 5 | type Query { 6 | unknownroot: UnknownType 7 | knownroot: KnownType 8 | } 9 | 10 | type KnownType { 11 | child: UnknownChildType 12 | } 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/schema_errors/unknown_type_on_root_and_outside.schema-error.ron: -------------------------------------------------------------------------------- 1 | MultipleErrors(DisplayVec([ 2 | UnknownPropertyOrEdgeType("child", "UnknownChildType"), 3 | UnknownPropertyOrEdgeType("unknownroot", "UnknownType"), 4 | ])) 5 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/alias_and_prefix_output_names.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | zero: value @output 7 | 8 | succ_: successor { 9 | is_named: name @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/alias_and_prefix_output_names.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "succ_is_named": Output( 5 | name: "succ_is_named", 6 | value_type: "String", 7 | vid: Vid(2), 8 | ), 9 | "zero": Output( 10 | name: "zero", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "succ_is_named": String("one"), 18 | "zero": Int64(0), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/alias_driven_output_names.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | zero: value @output 7 | 8 | succ_: successor { 9 | value @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/alias_driven_output_names.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "succ_value": Output( 5 | name: "succ_value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | "zero": Output( 10 | name: "zero", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "succ_value": Int64(1), 18 | "zero": Int64(0), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/alias_driven_tag_and_output_names.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | One { 6 | one: value @tag @output 7 | 8 | successor { 9 | value @output(name: "successor") @filter(op: ">", value: ["%one"]) 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/alias_driven_tag_and_output_names.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "one": Output( 5 | name: "one", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | "successor": Output( 10 | name: "successor", 11 | value_type: "Int", 12 | vid: Vid(2), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "one": Int64(1), 18 | "successor": Int64(2), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/avoid_output_name_conflict_with_alias_name.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | One { 6 | value @output 7 | 8 | successor { 9 | successor: value @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/avoid_output_name_conflict_with_alias_name.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "successor": Output( 5 | name: "successor", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "successor": Int64(2), 18 | "value": Int64(1), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/coercion_allows_additional_edge.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 10, max: 20) { 6 | ... on Composite { 7 | value @output 8 | 9 | primeFactor @fold { 10 | prime: value @output 11 | } 12 | } 13 | 14 | } 15 | }"#, 16 | arguments: {}, 17 | ) 18 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/coercion_on_edge.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | value @output 7 | 8 | successor { 9 | ... on Prime { 10 | prime: value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/coercion_on_folded_edge.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 6) { 6 | value @output 7 | 8 | predecessor @fold { 9 | ... on Prime { 10 | prime: value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/coercion_on_optional_edge.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 6) { 6 | value @output 7 | 8 | predecessor @optional { 9 | ... on Prime { 10 | prime: value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/coercion_on_recursed_edge.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 4) { 6 | value @output 7 | 8 | successor @recurse(depth: 3) { 9 | ... on Prime { 10 | prime: value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/duplicated_edge.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | successor { 7 | one: value @output 8 | } 9 | successor { 10 | one2: value @output 11 | } 12 | } 13 | }"#, 14 | arguments: {}, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/duplicated_edge.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "one": Output( 5 | name: "one", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | "one2": Output( 10 | name: "one2", 11 | value_type: "Int", 12 | vid: Vid(3), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "one": Int64(1), 18 | "one2": Int64(1), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/edge_parameter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | value @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/edge_parameters_on_non_root.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 3) { 6 | value @output 7 | 8 | multiple(max: 3) { 9 | multiple: value @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/empty_fold_output.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | value @output 7 | 8 | multiple(max: 10) @fold { 9 | mult: value @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/empty_fold_output.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "mult": Output( 5 | name: "mult", 6 | value_type: "[Int]!", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "mult": List([]), 18 | "value": Int64(0), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/execute_fold_before_traverse.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | One { 6 | successor { 7 | multiple(max: 3) @fold { 8 | mult: value @output 9 | } 10 | 11 | successor { 12 | succ: value @output 13 | } 14 | } 15 | } 16 | }"#, 17 | arguments: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/execute_fold_before_traverse.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "mult": Output( 5 | name: "mult", 6 | value_type: "[Int]!", 7 | vid: Vid(3), 8 | ), 9 | "succ": Output( 10 | name: "succ", 11 | value_type: "Int", 12 | vid: Vid(4), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "mult": List([ 18 | Int64(4), 19 | Int64(6), 20 | ]), 21 | "succ": Int64(3), 22 | }, 23 | ], 24 | ) 25 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/explicit_output_overrides_alias.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | One { 6 | one: value @output 7 | 8 | succ_: successor { 9 | name @output 10 | value @output(name: "two") 11 | } 12 | } 13 | }"#, 14 | arguments: {}, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_in_fold_using_external_tag.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | name @tag 7 | 8 | multiple(max: 3) @fold { 9 | name @filter(op: "<", value: ["%name"]) 10 | value @output 11 | } 12 | } 13 | }"#, 14 | arguments: {}, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_in_fold_using_external_tag.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "[Int]!", 7 | vid: Vid(2), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": List([ 13 | Int64(4), 14 | Int64(6), 15 | ]), 16 | }, 17 | ], 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_in_nested_fold_using_external_tag.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | name @tag 7 | 8 | multiple(max: 2) @fold { 9 | first: value @output 10 | 11 | multiple(max: 2) @fold { 12 | name @filter(op: "<", value: ["%name"]) 13 | second: value @output 14 | } 15 | } 16 | } 17 | }"#, 18 | arguments: {}, 19 | ) 20 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_contains.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 8, max: 11) { 6 | value @output 7 | vowelsInName @filter(op: "contains", value: ["$vowel"]) @output 8 | } 9 | }"#, 10 | arguments: { 11 | "vowel": String("i") 12 | }, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_greater_or_equal.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 8, max: 10) { 6 | value @output 7 | 8 | multiple(max: 4) { 9 | mult: value @output @filter(op: ">=", value: ["$num"]) 10 | } 11 | } 12 | }"#, 13 | arguments: { 14 | "num": Int64(24) 15 | }, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_greater_than.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 8, max: 10) { 6 | value @output 7 | 8 | multiple(max: 4) { 9 | mult: value @output @filter(op: ">", value: ["$num"]) 10 | } 11 | } 12 | }"#, 13 | arguments: { 14 | "num": Int64(25) 15 | }, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_has_prefix.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 4, max: 14) { 6 | name @output @filter(op: "has_prefix", value: ["$prefix"]) 7 | } 8 | }"#, 9 | arguments: { 10 | "prefix": String("four") 11 | }, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_has_prefix.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "name": Output( 5 | name: "name", 6 | value_type: "String", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "name": String("four"), 13 | }, 14 | { 15 | "name": String("fourteen"), 16 | }, 17 | ], 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_has_substring.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 10, max: 13) { 6 | name @output @filter(op: "has_substring", value: ["$substr"]) 7 | } 8 | }"#, 9 | arguments: { 10 | "substr": String("el") 11 | }, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_has_substring.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "name": Output( 5 | name: "name", 6 | value_type: "String", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "name": String("eleven"), 13 | }, 14 | { 15 | "name": String("twelve"), 16 | }, 17 | ], 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_has_suffix.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 12, max: 20) { 6 | name @output @filter(op: "has_suffix", value: ["$suffix"]) 7 | } 8 | }"#, 9 | arguments: { 10 | "suffix": String("teen") 11 | }, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_less_or_equal.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 8, max: 9) { 6 | value @output @filter(op: "<=", value: ["$num"]) 7 | } 8 | }"#, 9 | arguments: { 10 | "num": Int64(8) 11 | }, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_less_or_equal.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(8), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_less_than.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 8, max: 9) { 6 | value @output @filter(op: "<", value: ["$num"]) 7 | } 8 | }"#, 9 | arguments: { 10 | "num": Int64(9) 11 | }, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_less_than.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(8), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_not_equal.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 8, max: 9) { 6 | value @output @filter(op: "!=", value: ["$num"]) 7 | } 8 | }"#, 9 | arguments: { 10 | "num": Int64(8) 11 | }, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_not_equal.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(9), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_one_of.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 12, max: 16) { 6 | name @output @filter(op: "one_of", value: ["$options"]) 7 | } 8 | }"#, 9 | arguments: { 10 | "options": List([ 11 | String("fourteen"), 12 | String("fifteen"), 13 | ]) 14 | }, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_one_of.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "name": Output( 5 | name: "name", 6 | value_type: "String", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "name": String("fourteen"), 13 | }, 14 | { 15 | "name": String("fifteen"), 16 | }, 17 | ], 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_regex.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 12, max: 16) { 6 | name @output @filter(op: "regex", value: ["$pattern"]) 7 | } 8 | }"#, 9 | arguments: { 10 | "pattern": String("f.+teen") 11 | }, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_op_regex.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "name": Output( 5 | name: "name", 6 | value_type: "String", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "name": String("fourteen"), 13 | }, 14 | { 15 | "name": String("fifteen"), 16 | }, 17 | ], 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_with_omitted_value_arg.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 5, max: 22) { 6 | name @output @filter(op: "is_not_null") 7 | value @output 8 | } 9 | }"#, 10 | arguments: {}, 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_within_fold.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | multiple(max: 4) @fold { 7 | name @output 8 | value @filter(op: ">", value: ["$bound"]) 9 | } 10 | } 11 | }"#, 12 | arguments: { 13 | "bound": Int64(5) 14 | }, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/filter_within_fold.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "name": Output( 5 | name: "name", 6 | value_type: "[String]!", 7 | vid: Vid(2), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "name": List([ 13 | String("six"), 14 | String("eight"), 15 | ]), 16 | }, 17 | ], 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 4, max: 6) { 6 | ... on Composite { 7 | value @output 8 | 9 | primeFactor @fold @transform(op: "count") @filter(op: "=", value: ["$two"]) { 10 | factors: value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: { 16 | "two": Uint64(2), 17 | }, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "factors": Output( 5 | name: "factors", 6 | value_type: "[Int]!", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "factors": List([ 18 | Int64(2), 19 | Int64(3), 20 | ]), 21 | "value": Int64(6), 22 | }, 23 | ], 24 | ) 25 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter_early_prune_max_fold_size_equals.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 30, max: 32) { 6 | ... on Composite { 7 | value @output 8 | 9 | primeFactor @fold @transform(op: "count") @filter(op: "=", value: ["$one"]) { 10 | factors: value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: { 16 | "one": Uint64(1), 17 | }, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter_early_prune_max_fold_size_less.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 30, max: 32) { 6 | ... on Composite { 7 | value @output 8 | 9 | primeFactor @fold @transform(op: "count") @filter(op: "<", value: ["$two"]) { 10 | factors: value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: { 16 | "two": Uint64(2), 17 | }, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter_early_prune_max_fold_size_less_equals.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 30, max: 32) { 6 | ... on Composite { 7 | value @output 8 | 9 | primeFactor @fold @transform(op: "count") @filter(op: "<=", value: ["$one"]) { 10 | factors: value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: { 16 | "one": Uint64(1), 17 | }, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter_eq_with_negative_arg.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "factors": Output( 5 | name: "factors", 6 | value_type: "[Int]!", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [], 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter_lt_with_negative_arg.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "factors": Output( 5 | name: "factors", 6 | value_type: "[Int]!", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [], 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter_lte_with_negative_arg.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "factors": Output( 5 | name: "factors", 6 | value_type: "[Int]!", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [], 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter_on_a_tag.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | }, 10 | results: [], 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter_one_of_with_negative_arg.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "factors": Output( 5 | name: "factors", 6 | value_type: "[Int]!", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [], 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter_with_dominated_filter_gt.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [], 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter_with_dominated_filter_lt.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [], 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_filter_with_impossible_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [], 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_prefixed_output_name.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Four { 6 | factor_: primeFactor @fold @transform(op: "count") @output { 7 | numbers: value @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_tag_explicitly_named.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | successor @fold @transform(op: "count") @tag(name: "successor_count") 7 | 8 | predecessor { 9 | value @filter(op: "=", value: ["%successor_count"]) @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_tag_explicitly_named.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(3), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(1), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_tag_then_filter_on_fold.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | successor @fold @transform(op: "count") @tag(name: "successor_count") 7 | 8 | predecessor @fold 9 | @transform(op: "count") 10 | @filter(op: "=", value: ["%successor_count"]) 11 | @output 12 | } 13 | }"#, 14 | arguments: {}, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_tag_then_filter_on_fold.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "predecessorcount": Output( 5 | name: "predecessorcount", 6 | value_type: "Int!", 7 | vid: Vid(3), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "predecessorcount": Uint64(1), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_tag_used_inside_sibling_fold.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | value @output 7 | 8 | successor @fold @transform(op: "count") @tag(name: "tagged_count") 9 | 10 | predecessor @fold { 11 | value @filter(op: "=", value: ["%tagged_count"]) 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_count_tag_used_inside_sibling_fold.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(2), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_directive.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | multiple(max: 3) @fold { 7 | value @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_directive.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "[Int]!", 7 | vid: Vid(2), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": List([ 13 | Int64(4), 14 | Int64(6), 15 | ]), 16 | }, 17 | ], 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_count_filter_and_nested_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "inner": Output( 5 | name: "inner", 6 | value_type: "[Int]!", 7 | vid: Vid(3), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "inner": List([ 18 | Int64(1), 19 | ]), 20 | "value": Int64(1), 21 | }, 22 | ], 23 | ) 24 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_nested_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "[Int]!", 7 | vid: Vid(3), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": List([ 13 | Int64(1), 14 | ]), 15 | }, 16 | ], 17 | ) 18 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_nested_filter_and_tag.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "inner": Output( 5 | name: "inner", 6 | value_type: "[Int]!", 7 | vid: Vid(3), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "inner": List([ 18 | Int64(1), 19 | ]), 20 | "value": Int64(1), 21 | }, 22 | ], 23 | ) 24 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_no_inner_output_with_count_output.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "primeFactorcount": Output( 5 | name: "primeFactorcount", 6 | value_type: "Int!", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "primeFactorcount": Uint64(3), 18 | "value": Int64(30), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_no_outputs.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(30), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_no_outputs_elided_braces.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(30), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_no_outputs_transform_and_filter_greater_than.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(30), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_no_outputs_transform_and_filter_less_than.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 30, max: 32) { 6 | ... on Composite { 7 | value @output 8 | 9 | primeFactor @fold @transform(op: "count") @filter(op: "<", value: ["$min_primes"]) { 10 | __typename 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: { 16 | "min_primes": Uint64(2) 17 | }, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_no_outputs_transform_and_filter_less_than.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(32), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_no_outputs_transform_and_filter_one_of.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [], 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_outputs_transform_and_filter_greater_than.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 30, max: 30) { 6 | ... on Composite { 7 | value @output 8 | 9 | primeFactor @fold @transform(op: "count") @filter(op: ">", value: ["$min_primes"]) { 10 | prime: value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: { 16 | "min_primes": Uint64(1) 17 | }, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_outputs_transform_and_filter_less_than.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 30, max: 30) { 6 | ... on Composite { 7 | value @output 8 | 9 | primeFactor @fold @transform(op: "count") @filter(op: "<", value: ["$min_primes"]) { 10 | prime: value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: { 16 | "min_primes": Uint64(2) 17 | }, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/fold_with_outputs_transform_and_filter_less_than.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "prime": Output( 5 | name: "prime", 6 | value_type: "[Int]!", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [], 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/folded_filter_in_fold_using_external_tag.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | multiple(max: 2) @fold { 7 | name @tag 8 | first: value @output 9 | 10 | multiple(max: 2) @fold { 11 | name @filter(op: "<", value: ["%name"]) 12 | second: value @output 13 | } 14 | } 15 | } 16 | }"#, 17 | arguments: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/implicit_null_for_nullable_edge_parameter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | NumberImplicitNullDefault(max: 1) { 6 | value @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/implicit_null_for_nullable_edge_parameter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(0), 13 | }, 14 | { 15 | "value": Int64(1), 16 | }, 17 | ], 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/implicit_tag_and_output_names.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | One { 6 | value @tag @output 7 | 8 | successor { 9 | value @output(name: "successor_value") @filter(op: ">", value: ["%value"]) 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/implicit_tag_and_output_names.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "successor_value": Output( 5 | name: "successor_value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "successor_value": Int64(2), 18 | "value": Int64(1), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/multiple_copies_of_field.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | multiple(max: 3) { 7 | value @output 8 | value @filter(op: ">", value: ["$min_value"]) 9 | } 10 | } 11 | }"#, 12 | arguments: { 13 | "min_value": Int64(5), 14 | }, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/multiple_copies_of_field.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(6), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/multiple_fold_outputs.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | multiple(max: 6) @fold { 7 | name @output 8 | value @output 9 | } 10 | } 11 | }"#, 12 | arguments: {}, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/multiple_folds.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Four { 6 | value @output 7 | 8 | multiple(max: 2) @fold { 9 | mult: value @output 10 | } 11 | divisor @fold { 12 | div: value @output 13 | } 14 | } 15 | }"#, 16 | arguments: {}, 17 | ) 18 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nested_fold.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 5, max: 7) { 6 | base: value @output 7 | 8 | multiple(max: 3) @fold { 9 | value @output 10 | 11 | multiple(max: 3) @fold { 12 | mult: value @output 13 | } 14 | } 15 | } 16 | }"#, 17 | arguments: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nested_fold_with_no_outputs.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(64), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nested_query.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 3) { 6 | value @output 7 | 8 | successor { 9 | successor: value @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/no_op_fragment.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | successor { 7 | ... { 8 | value @output 9 | } 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/no_op_fragment.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(3), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_immediate_coercion.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | zero: value @output 7 | 8 | predecessor @optional { 9 | ... on Composite { 10 | value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_immediate_coercion.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | "zero": Output( 10 | name: "zero", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "value": Null, 18 | "zero": Int64(0), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_immediate_filter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | zero: value @output 7 | 8 | predecessor @optional { 9 | value @output @filter(op: "<", value: ["$zero"]) 10 | } 11 | } 12 | }"#, 13 | arguments: { 14 | "zero": Int64(0), 15 | }, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_immediate_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | "zero": Output( 10 | name: "zero", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "value": Null, 18 | "zero": Int64(0), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_immediate_is_not_null_filter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | zero: value @output 7 | 8 | predecessor @optional { 9 | value @output @filter(op: "is_not_null") 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_immediate_is_not_null_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | "zero": Output( 10 | name: "zero", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "value": Null, 18 | "zero": Int64(0), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_nested_coercion.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | zero: value @output 7 | 8 | predecessor @optional { 9 | successor { 10 | ... on Neither { 11 | value @output 12 | } 13 | } 14 | } 15 | } 16 | }"#, 17 | arguments: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_nested_coercion.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(3), 8 | ), 9 | "zero": Output( 10 | name: "zero", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "value": Null, 18 | "zero": Int64(0), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_nested_filter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | zero: value @output 7 | 8 | predecessor @optional { 9 | successor { 10 | value @output @filter(op: "=", value: ["$zero"]) 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: { 16 | "zero": Int64(0), 17 | }, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_nested_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(3), 8 | ), 9 | "zero": Output( 10 | name: "zero", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "value": Null, 18 | "zero": Int64(0), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_nested_is_not_null_filter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | zero: value @output 7 | 8 | predecessor @optional { 9 | successor { 10 | value @output @filter(op: "is_not_null") 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_nested_is_not_null_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(3), 8 | ), 9 | "zero": Output( 10 | name: "zero", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "value": Null, 18 | "zero": Int64(0), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_tagged_immediate_filter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | zero: value @output @tag 7 | 8 | predecessor @optional { 9 | value @output @filter(op: "<", value: ["%zero"]) 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_tagged_immediate_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | "zero": Output( 10 | name: "zero", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "value": Null, 18 | "zero": Int64(0), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_tagged_nested_filter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | zero: value @output @tag 7 | 8 | predecessor @optional { 9 | successor { 10 | value @output @filter(op: "=", value: ["%zero"]) 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/nonexistent_optional_with_tagged_nested_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(3), 8 | ), 9 | "zero": Output( 10 | name: "zero", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "value": Null, 18 | "zero": Int64(0), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/optional_directive.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 4) { 6 | value @output 7 | 8 | multiple(max: 3) @optional { 9 | mult: value @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/optional_with_nested_edge_and_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(3), 8 | ), 9 | }, 10 | results: [], 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/optional_with_nested_edge_with_filter_and_tag.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(3), 8 | ), 9 | }, 10 | results: [], 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/optional_with_nested_filter_semantics.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "predecessor": Output( 5 | name: "predecessor", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [], 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/optional_with_nested_filter_with_tag_semantics.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "predecessor": Output( 5 | name: "predecessor", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [], 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/optional_with_nested_required_edge_semantics.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(3), 8 | ), 9 | }, 10 | results: [], 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/output_fold_count.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Four { 6 | value @output 7 | 8 | primeFactor @fold @transform(op: "count") @output { 9 | factors: value @output 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/output_fold_count_multiple.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 28, max: 32) { 6 | ... on Composite { 7 | value @output 8 | 9 | primeFactor @fold @transform(op: "count") @output { 10 | factors: value @output 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/outputs_both_inside_and_outside_fold.graphql.ron: -------------------------------------------------------------------------------- 1 | // Query analogous to the one that triggers: 2 | // https://github.com/obi1kenobi/trustfall/issues/205 3 | TestGraphQLQuery ( 4 | schema_name: "numbers", 5 | query: r#" 6 | { 7 | Number(min: 1, max: 3) { 8 | value @output 9 | 10 | multiple(max: 3) @fold { 11 | multiple: value @output 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_and_traverse.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 4, max: 5) { 6 | base: value @output 7 | 8 | successor @recurse(depth: 3) { 9 | value @output 10 | 11 | multiple(max: 3) { 12 | mult: value @output 13 | } 14 | } 15 | } 16 | }"#, 17 | arguments: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_directive.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 3) { 6 | value @output 7 | successor @recurse(depth: 3) { 8 | next: value @output 9 | } 10 | } 11 | }"#, 12 | arguments: {}, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_on_parameterized_edge.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Four { 6 | multiple(max: 2) @recurse(depth: 3) { 7 | value @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_filter_depth_one.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 5) { 6 | successor @recurse(depth: 1) { 7 | value @output 8 | @filter(op: "=", value: ["$bound"]) 9 | } 10 | } 11 | }"#, 12 | arguments: { 13 | "bound": Int64(6) 14 | }, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_filter_depth_one.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(6), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_filter_depth_two.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 5) { 6 | successor @recurse(depth: 2) { 7 | value @output 8 | @filter(op: "=", value: ["$bound"]) 9 | } 10 | } 11 | }"#, 12 | arguments: { 13 | "bound": Int64(6) 14 | }, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_filter_depth_two.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(6), 13 | }, 14 | { 15 | "value": Int64(6), 16 | }, 17 | ], 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_filter_intermediate.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 5) { 6 | successor @recurse(depth: 3) { 7 | value @output 8 | @filter(op: "=", value: ["$bound"]) 9 | } 10 | } 11 | }"#, 12 | arguments: { 13 | "bound": Int64(6) 14 | }, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_filter_intermediate.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(6), 13 | }, 14 | { 15 | "value": Int64(6), 16 | }, 17 | { 18 | "value": Int64(6), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_filter_leaves.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 5) { 6 | successor @recurse(depth: 3) { 7 | value @output 8 | @filter(op: ">", value: ["$bound"]) 9 | } 10 | } 11 | }"#, 12 | arguments: { 13 | "bound": Int64(7) 14 | }, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_filter_leaves.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(2), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(8), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_filter_on_tag_depth_one.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 5) { 6 | value @tag(name: "bound") 7 | successor @recurse(depth: 1) { 8 | value @output 9 | @filter(op: ">", value: ["%bound"]) 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_filter_on_tag_depth_two.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 5) { 6 | value @tag(name: "bound") 7 | successor @recurse(depth: 2) { 8 | value @output 9 | @filter(op: ">", value: ["%bound"]) 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_nested_required_edge_depth_two.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | successor @recurse(depth: 2) { 7 | predecessor { 8 | predecessor { 9 | value @output 10 | } 11 | } 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_nested_required_edge_depth_two.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(4), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(0), 13 | }, 14 | { 15 | "value": Int64(1), 16 | }, 17 | { 18 | "value": Int64(2), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_required_edge_depth_one.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Two { 6 | successor @recurse(depth: 1) { 7 | predecessor { 8 | value @output 9 | } 10 | } 11 | } 12 | }"#, 13 | arguments: {}, 14 | ) 15 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/recurse_then_required_edge_depth_one.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(3), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(1), 13 | }, 14 | { 15 | "value": Int64(2), 16 | }, 17 | ], 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/required_properties.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 1, max: 2) { 6 | __typename @filter(op: "=", value: ["$type"]) 7 | value @output 8 | name @tag 9 | predecessor @fold { 10 | name @output 11 | } 12 | multiple(max: 5) { 13 | name @filter(op: "=", value: ["%name"]) 14 | } 15 | } 16 | }"#, 17 | arguments: { 18 | "type": String("Prime"), 19 | }, 20 | ) 21 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/required_properties.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "name": Output( 5 | name: "name", 6 | value_type: "[String]!", 7 | vid: Vid(2), 8 | ), 9 | "value": Output( 10 | name: "value", 11 | value_type: "Int", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [], 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/required_properties_filter_and_output.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 1, max: 2) { 6 | __typename @filter(op: "=", value: ["$type"]) 7 | value @output @filter(op: "=", value: ["$val"]) 8 | vowelsInName @output 9 | } 10 | }"#, 11 | arguments: { 12 | "type": String("Prime"), 13 | "val": Int64(7) 14 | }, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/required_properties_filter_and_output.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | "vowelsInName": Output( 10 | name: "vowelsInName", 11 | value_type: "[String]", 12 | vid: Vid(1), 13 | ), 14 | }, 15 | results: [], 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/root_coercion.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 10) { 6 | ... on Prime { 7 | value @output 8 | } 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/root_coercion.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(2), 13 | }, 14 | { 15 | "value": Int64(3), 16 | }, 17 | { 18 | "value": Int64(5), 19 | }, 20 | { 21 | "value": Int64(7), 22 | }, 23 | ], 24 | ) 25 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/simple_filter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 3) { 6 | name @output(name: "number_name") 7 | value @filter(op: "=", value: ["$value"]) 8 | } 9 | }"#, 10 | arguments: { 11 | "value": Int64(3) 12 | }, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/simple_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "number_name": Output( 5 | name: "number_name", 6 | value_type: "String", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "number_name": String("three"), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/simple_query.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(max: 3) { 6 | name @output(name: "number_name") 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/simple_query.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "number_name": Output( 5 | name: "number_name", 6 | value_type: "String", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "number_name": String("zero"), 13 | }, 14 | { 15 | "number_name": String("one"), 16 | }, 17 | { 18 | "number_name": String("two"), 19 | }, 20 | { 21 | "number_name": String("three"), 22 | }, 23 | ], 24 | ) 25 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/static_and_dynamic_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(3), 13 | }, 14 | { 15 | "value": Int64(4), 16 | }, 17 | ], 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/tag_and_filter_directives.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 2, max: 4) { 6 | value @tag(name: "start") @output(name: "start") 7 | 8 | predecessor { 9 | multiple(max: 3) { 10 | predecessor { 11 | value @output(name: "target") @filter(op: "=", value: ["%start"]) 12 | } 13 | } 14 | } 15 | } 16 | }"#, 17 | arguments: {}, 18 | ) 19 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/tag_and_filter_directives.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "start": Output( 5 | name: "start", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | "target": Output( 10 | name: "target", 11 | value_type: "Int", 12 | vid: Vid(4), 13 | ), 14 | }, 15 | results: [ 16 | { 17 | "start": Int64(3), 18 | "target": Int64(3), 19 | }, 20 | ], 21 | ) 22 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/tag_before_filter_in_same_scope.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | 4 | // The @tag comes after the @filter that uses it, 5 | // but they are within the same scope so that's not an error. 6 | query: r#" 7 | { 8 | One { 9 | vowelsInName @filter(op: "contains", value: ["%name"]) 10 | 11 | name @tag @output 12 | } 13 | }"#, 14 | arguments: {}, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/tag_before_filter_in_same_scope.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "name": Output( 5 | name: "name", 6 | value_type: "String", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [], 11 | ) 12 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/tag_name_in_prefixed_vertex.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 2, max: 3) { 6 | m1_: multiple(max: 3) { 7 | value @tag @output 8 | } 9 | 10 | m2_: multiple(max: 3) { 11 | value @output @filter(op: "=", value: ["%value"]) 12 | } 13 | } 14 | }"#, 15 | arguments: {}, 16 | ) 17 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/typename_filter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 1, max: 2) { 6 | __typename @filter(op: "=", value: ["$type"]) 7 | value @output 8 | } 9 | }"#, 10 | arguments: { 11 | "type": String("Prime"), 12 | }, 13 | ) 14 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/typename_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(2), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/typename_output.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Zero { 6 | __typename @output 7 | } 8 | }"#, 9 | arguments: {}, 10 | ) 11 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/typename_output.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "__typename": Output( 5 | name: "__typename", 6 | value_type: "String!", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "__typename": String("Neither"), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/typename_output_on_final_type.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | // The `Two` starting vertex is of type `Prime`, which has no subtypes. 4 | // It's possible to resolve this query without dynamically running `typename()` once per vertex. 5 | query: r#" 6 | { 7 | Two { 8 | __typename @output 9 | } 10 | }"#, 11 | arguments: {}, 12 | ) 13 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/typename_output_on_final_type.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "__typename": Output( 5 | name: "__typename", 6 | value_type: "String!", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "__typename": String("Prime"), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/typename_tag_and_filter.graphql.ron: -------------------------------------------------------------------------------- 1 | TestGraphQLQuery ( 2 | schema_name: "numbers", 3 | query: r#" 4 | { 5 | Number(min: 1, max: 2) { 6 | __typename @tag 7 | value @output 8 | 9 | successor { 10 | __typename @filter(op: "=", value: ["%__typename"]) 11 | } 12 | } 13 | }"#, 14 | arguments: {}, 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_core/test_data/tests/valid_queries/typename_tag_and_filter.output.ron: -------------------------------------------------------------------------------- 1 | TestInterpreterOutputData( 2 | schema_name: "numbers", 3 | outputs: { 4 | "value": Output( 5 | name: "value", 6 | value_type: "Int", 7 | vid: Vid(1), 8 | ), 9 | }, 10 | results: [ 11 | { 12 | "value": Int64(2), 13 | }, 14 | ], 15 | ) 16 | -------------------------------------------------------------------------------- /trustfall_derive/.gitignore: -------------------------------------------------------------------------------- 1 | # trybuild outputs for failed tests 2 | wip/* 3 | -------------------------------------------------------------------------------- /trustfall_derive/LICENSE.txt: -------------------------------------------------------------------------------- 1 | ../LICENSE.txt -------------------------------------------------------------------------------- /trustfall_derive/tests/ui/derive_struct.rs: -------------------------------------------------------------------------------- 1 | use trustfall_derive::{TrustfallEnumVertex, Typename}; 2 | 3 | #[derive(Debug, Clone, TrustfallEnumVertex)] 4 | struct Vertex { 5 | content: i64, 6 | } 7 | 8 | #[derive(Debug, Clone, Typename)] 9 | struct OtherVertex { 10 | content: i64, 11 | } 12 | 13 | fn main() {} 14 | -------------------------------------------------------------------------------- /trustfall_derive/tests/ui/derive_struct.stderr: -------------------------------------------------------------------------------- 1 | error: only enums can derive TrustfallEnumVertex 2 | --> tests/ui/derive_struct.rs:4:1 3 | | 4 | 4 | / struct Vertex { 5 | 5 | | content: i64, 6 | 6 | | } 7 | | |_^ 8 | 9 | error: only enums can derive Typename 10 | --> tests/ui/derive_struct.rs:9:1 11 | | 12 | 9 | / struct OtherVertex { 13 | 10 | | content: i64, 14 | 11 | | } 15 | | |_^ 16 | -------------------------------------------------------------------------------- /trustfall_derive/tests/ui/invalid_attr_as_path_only.rs: -------------------------------------------------------------------------------- 1 | use trustfall_derive::TrustfallEnumVertex; 2 | 3 | #[derive(Debug, Clone, TrustfallEnumVertex)] 4 | enum TwoVariants { 5 | #[trustfall] 6 | First, 7 | Second, 8 | } 9 | 10 | fn main() {} 11 | -------------------------------------------------------------------------------- /trustfall_derive/tests/ui/invalid_attr_as_path_only.stderr: -------------------------------------------------------------------------------- 1 | error: unexpected attribute, did you mean `#[trustfall(skip_conversion)]`? 2 | --> tests/ui/invalid_attr_as_path_only.rs:5:5 3 | | 4 | 5 | #[trustfall] 5 | | ^^^^^^^^^^^^ 6 | -------------------------------------------------------------------------------- /trustfall_derive/tests/ui/invalid_attr_unexpected_assignment.rs: -------------------------------------------------------------------------------- 1 | use trustfall_derive::TrustfallEnumVertex; 2 | 3 | #[derive(Debug, Clone, TrustfallEnumVertex)] 4 | enum Vertex { 5 | First, 6 | #[trustfall(skip_conversion = "yes")] 7 | Second, 8 | } 9 | 10 | fn main() {} 11 | -------------------------------------------------------------------------------- /trustfall_derive/tests/ui/invalid_attr_unexpected_assignment.stderr: -------------------------------------------------------------------------------- 1 | error: unexpected attribute, did you mean `#[trustfall(skip_conversion)]`? 2 | --> tests/ui/invalid_attr_unexpected_assignment.rs:6:5 3 | | 4 | 6 | #[trustfall(skip_conversion = "yes")] 5 | | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 6 | -------------------------------------------------------------------------------- /trustfall_derive/tests/ui/invalid_attr_unexpected_list_element.rs: -------------------------------------------------------------------------------- 1 | use trustfall_derive::TrustfallEnumVertex; 2 | 3 | #[derive(Debug, Clone, TrustfallEnumVertex)] 4 | enum One { 5 | #[trustfall(skip_conversion, unexpected_arg)] 6 | First, 7 | Second, 8 | } 9 | 10 | #[derive(Debug, Clone, TrustfallEnumVertex)] 11 | enum Other { 12 | First, 13 | #[trustfall(unexpected_arg, skip_conversion)] 14 | Second, 15 | } 16 | 17 | fn main() {} 18 | -------------------------------------------------------------------------------- /trustfall_derive/tests/ui/syntax_error.rs.broken: -------------------------------------------------------------------------------- 1 | use trustfall_derive::TrustfallEnumVertex; 2 | 3 | // Note the missing comma after the second variant. 4 | #[derive(Debug, Clone, TrustfallEnumVertex)] 5 | enum Vertex { 6 | User(String), 7 | Message { sender: String, content: String } 8 | EmptyVariant, 9 | } 10 | 11 | fn main() {} 12 | -------------------------------------------------------------------------------- /trustfall_filetests_macros/LICENSE.txt: -------------------------------------------------------------------------------- 1 | ../LICENSE.txt -------------------------------------------------------------------------------- /trustfall_stubgen/LICENSE.txt: -------------------------------------------------------------------------------- 1 | ../LICENSE.txt -------------------------------------------------------------------------------- /trustfall_stubgen/test_data/expected_outputs/hackernews/adapter/mod.rs: -------------------------------------------------------------------------------- 1 | mod adapter_impl; 2 | mod vertex; 3 | mod entrypoints; 4 | mod properties; 5 | mod edges; 6 | 7 | #[cfg(test)] 8 | mod tests; 9 | 10 | pub use adapter_impl::Adapter; 11 | pub use vertex::Vertex; 12 | -------------------------------------------------------------------------------- /trustfall_stubgen/test_data/expected_outputs/hackernews/adapter/tests.rs: -------------------------------------------------------------------------------- 1 | use trustfall::provider::check_adapter_invariants; 2 | 3 | use super::Adapter; 4 | 5 | #[test] 6 | fn adapter_satisfies_trustfall_invariants() { 7 | let adapter = Adapter::new(); 8 | let schema = Adapter::schema(); 9 | check_adapter_invariants(schema, adapter); 10 | } 11 | -------------------------------------------------------------------------------- /trustfall_stubgen/test_data/expected_outputs/hackernews/adapter/vertex.rs: -------------------------------------------------------------------------------- 1 | #[non_exhaustive] 2 | #[derive(Debug, Clone, trustfall::provider::TrustfallEnumVertex)] 3 | pub enum Vertex { 4 | Comment(()), 5 | Item(()), 6 | Job(()), 7 | Story(()), 8 | User(()), 9 | Webpage(()), 10 | } 11 | -------------------------------------------------------------------------------- /trustfall_stubgen/test_data/expected_outputs/no_edges/adapter/edges.rs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/obi1kenobi/trustfall/400f2dde891efdf19c3eb7b0b35903f9a1517413/trustfall_stubgen/test_data/expected_outputs/no_edges/adapter/edges.rs -------------------------------------------------------------------------------- /trustfall_stubgen/test_data/expected_outputs/no_edges/adapter/mod.rs: -------------------------------------------------------------------------------- 1 | mod adapter_impl; 2 | mod vertex; 3 | mod entrypoints; 4 | mod properties; 5 | mod edges; 6 | 7 | #[cfg(test)] 8 | mod tests; 9 | 10 | pub use adapter_impl::Adapter; 11 | pub use vertex::Vertex; 12 | -------------------------------------------------------------------------------- /trustfall_stubgen/test_data/expected_outputs/no_edges/adapter/tests.rs: -------------------------------------------------------------------------------- 1 | use trustfall::provider::check_adapter_invariants; 2 | 3 | use super::Adapter; 4 | 5 | #[test] 6 | fn adapter_satisfies_trustfall_invariants() { 7 | let adapter = Adapter::new(); 8 | let schema = Adapter::schema(); 9 | check_adapter_invariants(schema, adapter); 10 | } 11 | -------------------------------------------------------------------------------- /trustfall_stubgen/test_data/expected_outputs/no_edges/adapter/vertex.rs: -------------------------------------------------------------------------------- 1 | #[non_exhaustive] 2 | #[derive(Debug, Clone, trustfall::provider::TrustfallEnumVertex)] 3 | pub enum Vertex { 4 | Item(()), 5 | } 6 | -------------------------------------------------------------------------------- /trustfall_stubgen/test_data/expected_outputs/use_reserved_rust_names_in_schema/adapter/mod.rs: -------------------------------------------------------------------------------- 1 | mod adapter_impl; 2 | mod vertex; 3 | mod entrypoints; 4 | mod properties; 5 | mod edges; 6 | 7 | #[cfg(test)] 8 | mod tests; 9 | 10 | pub use adapter_impl::Adapter; 11 | pub use vertex::Vertex; 12 | -------------------------------------------------------------------------------- /trustfall_stubgen/test_data/expected_outputs/use_reserved_rust_names_in_schema/adapter/tests.rs: -------------------------------------------------------------------------------- 1 | use trustfall::provider::check_adapter_invariants; 2 | 3 | use super::Adapter; 4 | 5 | #[test] 6 | fn adapter_satisfies_trustfall_invariants() { 7 | let adapter = Adapter::new(); 8 | let schema = Adapter::schema(); 9 | check_adapter_invariants(schema, adapter); 10 | } 11 | -------------------------------------------------------------------------------- /trustfall_stubgen/test_data/expected_outputs/use_reserved_rust_names_in_schema/adapter/vertex.rs: -------------------------------------------------------------------------------- 1 | #[non_exhaustive] 2 | #[derive(Debug, Clone, trustfall::provider::TrustfallEnumVertex)] 3 | pub enum Vertex { 4 | Const(()), 5 | Const2(()), 6 | Continue(()), 7 | Continue2(()), 8 | Dyn(()), 9 | Dyn2(()), 10 | If(()), 11 | If2(()), 12 | Mod(()), 13 | Mod2(()), 14 | Self_(()), 15 | Self2(()), 16 | Type(()), 17 | Type2(()), 18 | Unsafe(()), 19 | Unsafe2(()), 20 | Where(()), 21 | Where2(()), 22 | } 23 | -------------------------------------------------------------------------------- /trustfall_testbin/LICENSE.txt: -------------------------------------------------------------------------------- 1 | ../LICENSE.txt -------------------------------------------------------------------------------- /trustfall_wasm/LICENSE.txt: -------------------------------------------------------------------------------- 1 | ../LICENSE.txt -------------------------------------------------------------------------------- /trustfall_wasm/www/.gitignore: -------------------------------------------------------------------------------- 1 | node_modules 2 | dist 3 | -------------------------------------------------------------------------------- /trustfall_wasm/www/bootstrap.js: -------------------------------------------------------------------------------- 1 | // A dependency graph that contains any wasm must all be imported 2 | // asynchronously. This `bootstrap.js` file does the single async import, so 3 | // that no one else needs to worry about it again. 4 | import("./index.js") 5 | .catch(e => console.error("Error importing `index.js`:", e)); 6 | -------------------------------------------------------------------------------- /trustfall_wasm/www/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | Hello trustfall_wasm! 6 | 7 | 8 | 9 | 10 | 11 | 12 | --------------------------------------------------------------------------------