diff --git a/_test_yaml/test/ensure_build_test.dart b/_test_yaml/test/ensure_build_test.dart index 4de07e5ee..868332ed6 100644 --- a/_test_yaml/test/ensure_build_test.dart +++ b/_test_yaml/test/ensure_build_test.dart @@ -4,6 +4,8 @@ @TestOn('vm') @Tags(['presubmit-only']) +library test; + import 'package:build_verify/build_verify.dart'; import 'package:test/test.dart'; diff --git a/_test_yaml/test/yaml_test.dart b/_test_yaml/test/yaml_test.dart index 428587d78..96f698b05 100644 --- a/_test_yaml/test/yaml_test.dart +++ b/_test_yaml/test/yaml_test.dart @@ -3,6 +3,8 @@ // BSD-style license that can be found in the LICENSE file. @TestOn('vm') +library test; + import 'dart:io'; import 'package:_json_serial_shared_test/shared_test.dart'; diff --git a/analysis_options.yaml b/analysis_options.yaml index eb8ce5989..8a6ede19c 100644 --- a/analysis_options.yaml +++ b/analysis_options.yaml @@ -16,9 +16,14 @@ linter: - avoid_void_async - cancel_subscriptions - cascade_invocations + - collection_methods_unrelated_type + - combinators_ordering - comment_references + - dangling_library_doc_comments - directives_ordering + - implicit_call_tearoffs - join_return_with_assignment + - library_annotations - lines_longer_than_80_chars - literal_only_boolean_expressions - missing_whitespace_between_adjacent_strings @@ -40,10 +45,13 @@ linter: - type_annotate_public_apis - unawaited_futures - unnecessary_lambdas + - unnecessary_library_directive - unnecessary_parenthesis - unnecessary_statements + - unreachable_from_main - unsafe_html - use_full_hex_values_for_flutter_colors - use_is_even_rather_than_modulo - use_string_buffers + - use_string_in_part_of_directives - use_super_parameters diff --git a/checked_yaml/test/ensure_build_test.dart b/checked_yaml/test/ensure_build_test.dart index 088218dcf..0a5935d7b 100644 --- a/checked_yaml/test/ensure_build_test.dart +++ b/checked_yaml/test/ensure_build_test.dart @@ -4,6 +4,8 @@ @TestOn('vm') @Tags(['presubmit-only']) +library test; + import 'package:build_verify/build_verify.dart'; import 'package:test/test.dart'; diff --git a/example/test/ensure_build_test.dart b/example/test/ensure_build_test.dart index 7fd35a448..5d06a2fd1 100644 --- a/example/test/ensure_build_test.dart +++ b/example/test/ensure_build_test.dart @@ -3,6 +3,8 @@ // BSD-style license that can be found in the LICENSE file. @Tags(['presubmit-only']) +library test; + import 'package:build_verify/build_verify.dart'; import 'package:test/test.dart'; diff --git a/json_serializable/lib/type_helper.dart b/json_serializable/lib/type_helper.dart index d79a2ada7..4caa64137 100644 --- a/json_serializable/lib/type_helper.dart +++ b/json_serializable/lib/type_helper.dart @@ -4,7 +4,7 @@ export 'src/shared_checkers.dart' show simpleJsonTypeChecker; export 'src/type_helper.dart' - show TypeHelperContext, TypeHelperContextWithConfig, TypeHelper; + show TypeHelper, TypeHelperContext, TypeHelperContextWithConfig; export 'src/type_helpers/big_int_helper.dart'; export 'src/type_helpers/config_types.dart'; export 'src/type_helpers/convert_helper.dart'; diff --git a/json_serializable/test/annotation_version_test.dart b/json_serializable/test/annotation_version_test.dart index 1ff0b4d62..349ca8b6d 100644 --- a/json_serializable/test/annotation_version_test.dart +++ b/json_serializable/test/annotation_version_test.dart @@ -4,6 +4,8 @@ @TestOn('vm') @Tags(['presubmit-only']) +library test; + import 'dart:io'; import 'package:json_serializable/src/check_dependencies.dart'; diff --git a/json_serializable/test/config_test.dart b/json_serializable/test/config_test.dart index 5c8dcef0e..a8355f117 100644 --- a/json_serializable/test/config_test.dart +++ b/json_serializable/test/config_test.dart @@ -3,6 +3,8 @@ // BSD-style license that can be found in the LICENSE file. @TestOn('vm') +library test; + import 'dart:io'; import 'package:build/build.dart'; diff --git a/json_serializable/test/custom_configuration_test.dart b/json_serializable/test/custom_configuration_test.dart index 649815905..8fc7ce097 100644 --- a/json_serializable/test/custom_configuration_test.dart +++ b/json_serializable/test/custom_configuration_test.dart @@ -3,6 +3,8 @@ // BSD-style license that can be found in the LICENSE file. @TestOn('vm') +library test; + import 'dart:async'; import 'package:analyzer/dart/element/type.dart'; diff --git a/json_serializable/test/default_value/default_value.dart b/json_serializable/test/default_value/default_value.dart index 65a8fe9ad..0894af857 100644 --- a/json_serializable/test/default_value/default_value.dart +++ b/json_serializable/test/default_value/default_value.dart @@ -9,9 +9,9 @@ import 'package:json_annotation/json_annotation.dart'; import 'default_value_interface.dart' as dvi hide Greek; import 'default_value_interface.dart' show - Greek, ConstClass, ConstClassConverter, + Greek, constClassFromJson, constClassToJson, intDefaultValueFunction; diff --git a/json_serializable/test/default_value/default_value.g_any_map__checked.dart b/json_serializable/test/default_value/default_value.g_any_map__checked.dart index 07e12fb29..be46b0133 100644 --- a/json_serializable/test/default_value/default_value.g_any_map__checked.dart +++ b/json_serializable/test/default_value/default_value.g_any_map__checked.dart @@ -9,9 +9,9 @@ import 'package:json_annotation/json_annotation.dart'; import 'default_value_interface.dart' as dvi hide Greek; import 'default_value_interface.dart' show - Greek, ConstClass, ConstClassConverter, + Greek, constClassFromJson, constClassToJson, intDefaultValueFunction; diff --git a/json_serializable/test/ensure_build_test.dart b/json_serializable/test/ensure_build_test.dart index de538c834..a8c75e638 100644 --- a/json_serializable/test/ensure_build_test.dart +++ b/json_serializable/test/ensure_build_test.dart @@ -4,6 +4,8 @@ @TestOn('vm') @Tags(['presubmit-only']) +library test; + import 'package:build_verify/build_verify.dart'; import 'package:test/test.dart'; diff --git a/json_serializable/test/enum_helper_test.dart b/json_serializable/test/enum_helper_test.dart index 4399dc843..cfc18ad9b 100644 --- a/json_serializable/test/enum_helper_test.dart +++ b/json_serializable/test/enum_helper_test.dart @@ -3,6 +3,8 @@ // BSD-style license that can be found in the LICENSE file. @TestOn('vm') +library test; + import 'package:json_serializable/src/type_helpers/enum_helper.dart'; import 'package:test/test.dart'; diff --git a/json_serializable/test/json_serializable_test.dart b/json_serializable/test/json_serializable_test.dart index 8affde81c..5644b51cb 100644 --- a/json_serializable/test/json_serializable_test.dart +++ b/json_serializable/test/json_serializable_test.dart @@ -3,6 +3,8 @@ // BSD-style license that can be found in the LICENSE file. @TestOn('vm') +library test; + import 'package:json_serializable/json_serializable.dart'; import 'package:path/path.dart' as p; import 'package:source_gen_test/source_gen_test.dart'; diff --git a/json_serializable/test/literal/json_literal_test.dart b/json_serializable/test/literal/json_literal_test.dart index d8d6c2643..edcb7855f 100644 --- a/json_serializable/test/literal/json_literal_test.dart +++ b/json_serializable/test/literal/json_literal_test.dart @@ -3,6 +3,8 @@ // BSD-style license that can be found in the LICENSE file. @TestOn('vm') +library test; + import 'dart:convert'; import 'dart:io'; diff --git a/json_serializable/test/supported_types/extra_map_test.dart b/json_serializable/test/supported_types/extra_map_test.dart index 0bdea277c..449a8d9ba 100644 --- a/json_serializable/test/supported_types/extra_map_test.dart +++ b/json_serializable/test/supported_types/extra_map_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.bigint_test.dart b/json_serializable/test/supported_types/type_test.bigint_test.dart index 579298f0e..26e7a001b 100644 --- a/json_serializable/test/supported_types/type_test.bigint_test.dart +++ b/json_serializable/test/supported_types/type_test.bigint_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.bool_test.dart b/json_serializable/test/supported_types/type_test.bool_test.dart index 1d66ca8ce..19247a81c 100644 --- a/json_serializable/test/supported_types/type_test.bool_test.dart +++ b/json_serializable/test/supported_types/type_test.bool_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.dart b/json_serializable/test/supported_types/type_test.dart index 1a94d75ed..1d5d72ded 100644 --- a/json_serializable/test/supported_types/type_test.dart +++ b/json_serializable/test/supported_types/type_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.datetime_test.dart b/json_serializable/test/supported_types/type_test.datetime_test.dart index 5e16b81e5..dee0b5cf5 100644 --- a/json_serializable/test/supported_types/type_test.datetime_test.dart +++ b/json_serializable/test/supported_types/type_test.datetime_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.double_test.dart b/json_serializable/test/supported_types/type_test.double_test.dart index c9db8891a..4704157ff 100644 --- a/json_serializable/test/supported_types/type_test.double_test.dart +++ b/json_serializable/test/supported_types/type_test.double_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.duration_test.dart b/json_serializable/test/supported_types/type_test.duration_test.dart index c19af16cd..f7651278c 100644 --- a/json_serializable/test/supported_types/type_test.duration_test.dart +++ b/json_serializable/test/supported_types/type_test.duration_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.enumtype_test.dart b/json_serializable/test/supported_types/type_test.enumtype_test.dart index 568ddb615..cd2b527e4 100644 --- a/json_serializable/test/supported_types/type_test.enumtype_test.dart +++ b/json_serializable/test/supported_types/type_test.enumtype_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.int_test.dart b/json_serializable/test/supported_types/type_test.int_test.dart index 9f5a81b1f..9f36677dd 100644 --- a/json_serializable/test/supported_types/type_test.int_test.dart +++ b/json_serializable/test/supported_types/type_test.int_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.iterable_test.dart b/json_serializable/test/supported_types/type_test.iterable_test.dart index 658ed97e1..a9c34fee7 100644 --- a/json_serializable/test/supported_types/type_test.iterable_test.dart +++ b/json_serializable/test/supported_types/type_test.iterable_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.list_test.dart b/json_serializable/test/supported_types/type_test.list_test.dart index adbd2ed4a..007a386a3 100644 --- a/json_serializable/test/supported_types/type_test.list_test.dart +++ b/json_serializable/test/supported_types/type_test.list_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.map_test.dart b/json_serializable/test/supported_types/type_test.map_test.dart index e814f7bd2..54a37fa9c 100644 --- a/json_serializable/test/supported_types/type_test.map_test.dart +++ b/json_serializable/test/supported_types/type_test.map_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.num_test.dart b/json_serializable/test/supported_types/type_test.num_test.dart index 1ebf28dbe..8bc9e72b5 100644 --- a/json_serializable/test/supported_types/type_test.num_test.dart +++ b/json_serializable/test/supported_types/type_test.num_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.object_test.dart b/json_serializable/test/supported_types/type_test.object_test.dart index 7f8e7f4b6..c7f28dd71 100644 --- a/json_serializable/test/supported_types/type_test.object_test.dart +++ b/json_serializable/test/supported_types/type_test.object_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.set_test.dart b/json_serializable/test/supported_types/type_test.set_test.dart index 1a0c0133d..4dfc0b82f 100644 --- a/json_serializable/test/supported_types/type_test.set_test.dart +++ b/json_serializable/test/supported_types/type_test.set_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.string_test.dart b/json_serializable/test/supported_types/type_test.string_test.dart index c239eab85..f7ed73127 100644 --- a/json_serializable/test/supported_types/type_test.string_test.dart +++ b/json_serializable/test/supported_types/type_test.string_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert'; diff --git a/json_serializable/test/supported_types/type_test.uri_test.dart b/json_serializable/test/supported_types/type_test.uri_test.dart index b60773780..4b8493ca4 100644 --- a/json_serializable/test/supported_types/type_test.uri_test.dart +++ b/json_serializable/test/supported_types/type_test.uri_test.dart @@ -4,6 +4,7 @@ // ignore_for_file: prefer_const_declarations @TestOn('vm') +library test; import 'dart:convert';