Add @isTest and @isTestGroup to package:meta

R=devoncarew@google.com, paulberry@google.com

Bug: https://github.com/flutter/flutter-intellij/issues/2055
Change-Id: I78083783a3e05171746253101b3b10bbdcc8ef99
Reviewed-on: https://dart-review.googlesource.com/53480
Reviewed-by: Paul Berry <paulberry@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
This commit is contained in:
Konstantin Shcheglov 2018-05-03 04:39:04 +00:00 committed by commit-bot@chromium.org
parent 3fcb85a545
commit f64ba0cadd

View file

@ -105,6 +105,22 @@ const _Factory factory = const _Factory();
/// class that has this annotation is not immutable.
const Immutable immutable = const Immutable();
/// Used to annotate a test framework function that runs a single test.
///
/// Tools, such as IDEs, can show invocations of such function in a file
/// structure view to help the user navigating in large test files.
///
/// The first parameter of the function must be the description of the test.
const _IsTest isTest = const _IsTest();
/// Used to annotate a test framework function that runs a group of tests.
///
/// Tools, such as IDEs, can show invocations of such function in a file
/// structure view to help the user navigating in large test files.
///
/// The first parameter of the function must be the description of the group.
const _IsTestGroup isTestGroup = const _IsTestGroup();
/// Used to annotate a const constructor `c`. Indicates that any invocation of
/// the constructor must use the keyword `const` unless one or more of the
/// arguments to the constructor is not a compile-time constant.
@ -244,6 +260,14 @@ class _Factory {
const _Factory();
}
class _IsTest {
const _IsTest();
}
class _IsTestGroup {
const _IsTestGroup();
}
class _Literal {
const _Literal();
}