dart-sdk/pkg
Brian Wilkerson 5fc437e6f2 Use shared mock packages in linter
I believe that this removes the last of the mock packages from the
linter. I went ahead and created shared mock packages for everything
supported in 'analyzer' even though the linter doesn't use all of them.

Change-Id: I83a9f83a9c9cca7c6969ffade3d0b11c1ec54fd1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/372220
Reviewed-by: Sam Rawlins <srawlins@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2024-06-19 14:07:19 +00:00
..
_fe_analyzer_shared [analyzer/cfe] Replace StackListener.importUri with isDartLibrary 2024-06-19 12:47:21 +00:00
_js_interop_checks [dart:js_interop] Add static error for converted functions that contain named params 2024-06-14 19:42:10 +00:00
_macros skip failing macro test 2024-06-12 20:59:34 +00:00
analysis_server analyzer: Deprecate dead properties on Comment 2024-06-18 18:27:25 +00:00
analysis_server_client
analysis_server_plugin analyzer: Fix resolution of private extension members 2024-06-17 18:28:21 +00:00
analyzer [analyzer/cfe] Replace StackListener.importUri with isDartLibrary 2024-06-19 12:47:21 +00:00
analyzer_cli
analyzer_plugin Expose CommentToken as analyzer public API 2024-06-18 17:34:27 +00:00
analyzer_utilities Use shared mock packages in linter 2024-06-19 14:07:19 +00:00
async_helper
bisect_dart
build_integration
compiler [dart2js] Use patterns for HIndex simplifications 2024-06-18 23:19:28 +00:00
dart2js_info
dart2js_runtime_metrics
dart2js_tools
dart2native
dart2wasm [dart2wasm] Specialize string interpolation expressions for 1/2/3/4 arguments 2024-06-14 12:33:51 +00:00
dart_internal
dart_service_protocol_shared
dartdev [analyzer] Prioritize errors in analysis_options/pubspec errors when running "dart analyze" 2024-06-18 17:29:16 +00:00
dds [ DDS ] Remove extra stderr.close() 2024-06-17 14:44:22 +00:00
dds_service_extensions
dev_compiler
dtd
dtd_impl [dtd] Allow passing an explicit port to DTD 2024-06-17 14:58:19 +00:00
expect
front_end [analyzer/cfe] Replace StackListener.importUri with isDartLibrary 2024-06-19 12:47:21 +00:00
frontend_server
heap_snapshot
js Add topics to pubspec.yaml 2024-06-13 13:02:54 +00:00
js_ast
js_runtime
js_shared
json
kernel [cfe] Local functions named _ are not in scope. 2024-06-14 22:31:48 +00:00
language_versioning_2_12_test
linter Use shared mock packages in linter 2024-06-19 14:07:19 +00:00
macros Macro. Re-export package:_macros/src/executor/response_impls.dart from 'package:macros'. 2024-06-13 19:12:41 +00:00
meta
mmap
modular_test
native_stack_traces
reload_test
scrape
server_plugin
smith [test] isVmAotConfiguration in custom configurations 2024-06-19 08:49:29 +00:00
sourcemap_testing Bump collection to c90b19f07b48391f3b1b4c39dd06ef0177f8e07c 2024-06-11 17:27:21 +00:00
status_file [status_files] Cleanup status files 2024-06-12 10:21:23 +00:00
telemetry
test_runner
testing
vm [deps] rev async, dartdoc, http_parser, shelf 2024-06-18 19:48:38 +00:00
vm_service [VM] Add RecordCoverage to InstanceCall and StaticCall 2024-06-17 10:47:58 +00:00
vm_service_interface
vm_service_protos
vm_snapshot_analysis
wasm_builder
.gitignore
analysis_options.yaml
BUILD.gn
OWNERS
pkg.dart
pkg.status [VM] Add RecordCoverage to InstanceCall and StaticCall 2024-06-17 10:47:58 +00:00
README.md

Package validation

The packages in pkg/ are automatically validated on the LUCI CI bots. The validation is largely done by the tools/package_deps package; it can be tested locally via:

dart tools/package_deps/bin/package_deps.dart

Packages which are published

There are several packages developed in pkg/ which are published to pub. Validation of these packages is particularly important because the pub tools are not used for these packages during development; we get our dependency versions from the DEPS file. It's very easy for the dependencies specified in a package's pubspec file to get out of date wrt the packages and versions actually used.

In order to better ensure we're publishing correct packages, we validate some properties of the pubspec files on our CI system. These validations include:

  • that the dependencies listed in the pubspec are used in the package
  • that all the packages used by the source are listed in the pubspec
  • that we don't use relative path deps to pkg/ or third_party/ packages

Packages which are not published

For packages in pkg/ which we do not intend to be published, we put the following comment in the pubspec.yaml file:

# This package is not intended for consumption on pub.dev. DO NOT publish.
publish_to: none

These pubspecs are still validated by the package validation tool. The contents are more informational as the pubspecs for these packages are not consumed by the pub tool or ecosystem.

We validate:

  • that the dependencies listed in the pubspec are used in the package
  • that all the packages used by the source are listed in the pubspec
  • that a reference to a pkg/ package is done via a relative path dependency