testing library
Testing utilities for package resolution in tests and integration suites.
Functions
-
capturePrints(
FutureOr< void> action()) → Future<String> -
Runs
actionin a Zone where print calls are intercepted, returning all printed lines as a single string. -
resolvePackageDirectory(
String packageUri) → Future< String> -
Resolves the root directory path of a package given a
packageUristring (e.g.'package:undead/undead.dart'). -
resolvePackageExecutable(
String packageUri, [String? executableName]) → Future< String> -
Resolves the absolute path to an executable in
bin/given apackageUriand an optionalexecutableName. -
resolvePackageFile(
String packageUri, String relativePath) → Future< File> -
Resolves a File relative to a package root given a
packageUristring and arelativePath(e.g.'pubspec.yaml').