chore(lint): fixed package lint errors
This commit is contained in:
parent
51ff178790
commit
6e82b95d09
|
@ -1,3 +1,6 @@
|
|||
## [0.0.12] - 06/02/2019
|
||||
* Fixed package analysis error
|
||||
|
||||
## [0.0.11] - 06/02/2019
|
||||
|
||||
* Fixes issue with table parameters not being given to step
|
||||
|
|
|
@ -21,7 +21,7 @@ class TestConfiguration {
|
|||
String tagExpression;
|
||||
|
||||
/// The default step timeout - this can be override when definition a step definition
|
||||
Duration defaultTimeout = Duration(seconds: 10);
|
||||
Duration defaultTimeout = const Duration(seconds: 10);
|
||||
|
||||
/// The execution order of features - this default to random to avoid any inter-test depedencies
|
||||
ExecutionOrder order = ExecutionOrder.random;
|
||||
|
|
|
@ -68,6 +68,7 @@ class FlutterRunProcessHandler extends ProcessHandler {
|
|||
completer.completeError(TimeoutException(
|
||||
"Timeout while wait for observatory debugger uri", timeout));
|
||||
}).listen((logLine) {
|
||||
// stdout.write(logLine);
|
||||
if (_observatoryDebuggerUriRegex.hasMatch(logLine)) {
|
||||
sub?.cancel();
|
||||
if (!completer.isCompleted)
|
||||
|
|
|
@ -28,7 +28,6 @@ class FlutterTestConfiguration extends TestConfiguration {
|
|||
Platform.environment['VM_SERVICE_URL'];
|
||||
final driver = await FlutterDriver.connect(
|
||||
dartVmServiceUrl: dartVmServiceUrl,
|
||||
isolateReadyTimeout: const Duration(seconds: 30),
|
||||
logCommunicationToFile: false,
|
||||
printCommunication: false);
|
||||
return driver;
|
||||
|
|
16
pubspec.lock
16
pubspec.lock
|
@ -7,7 +7,7 @@ packages:
|
|||
name: analyzer
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.34.3"
|
||||
version: "0.35.0"
|
||||
args:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -92,7 +92,7 @@ packages:
|
|||
name: front_end
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.1.9+1"
|
||||
version: "0.1.10"
|
||||
fuchsia_remote_debug_protocol:
|
||||
dependency: transitive
|
||||
description: flutter
|
||||
|
@ -167,7 +167,7 @@ packages:
|
|||
name: kernel
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.3.9+1"
|
||||
version: "0.3.10"
|
||||
logging:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -333,7 +333,7 @@ packages:
|
|||
name: source_span
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.4.1"
|
||||
version: "1.5.4"
|
||||
stack_trace:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -361,28 +361,28 @@ packages:
|
|||
name: term_glyph
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.0.1"
|
||||
version: "1.1.0"
|
||||
test:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: test
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.5.1+1"
|
||||
version: "1.5.3"
|
||||
test_api:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: test_api
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.2.1"
|
||||
version: "0.2.2"
|
||||
test_core:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: test_core
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.2.0+1"
|
||||
version: "0.2.1+1"
|
||||
typed_data:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
name: flutter_gherkin
|
||||
description: A Gherkin / Cucumber parser and test runner for Dart and Flutter
|
||||
version: 0.0.11
|
||||
version: 0.0.12
|
||||
author: Jon Samwell <jonsamwell@gmail.com>
|
||||
homepage: https://github.com/jonsamwell/flutter_gherkin
|
||||
|
||||
|
|
|
@ -322,11 +322,12 @@ void main() {
|
|||
final reporterMock = ReporterMock();
|
||||
reporterMock.onStepFinishedFn = (message) => finishedMessage = message;
|
||||
final stepDefiniton = MockStepDefinition(
|
||||
(_) async => await Future.delayed(Duration(seconds: 2)));
|
||||
(_) async => await Future.delayed(const Duration(seconds: 2)));
|
||||
final executableStep =
|
||||
ExectuableStep(MockGherkinExpression((_) => true), stepDefiniton);
|
||||
final runner = FeatureFileRunner(
|
||||
TestConfiguration()..defaultTimeout = Duration(milliseconds: 1),
|
||||
TestConfiguration()
|
||||
..defaultTimeout = const Duration(milliseconds: 1),
|
||||
MockTagExpressionEvaluator(),
|
||||
[executableStep],
|
||||
reporterMock,
|
||||
|
@ -366,7 +367,8 @@ void main() {
|
|||
MockGherkinExpression((s) => s == stepTextThree),
|
||||
stepDefinitonThree);
|
||||
final runner = FeatureFileRunner(
|
||||
TestConfiguration()..defaultTimeout = Duration(milliseconds: 1),
|
||||
TestConfiguration()
|
||||
..defaultTimeout = const Duration(milliseconds: 1),
|
||||
MockTagExpressionEvaluator(),
|
||||
[executableStep, executableStepTwo, executableStepThree],
|
||||
reporterMock,
|
||||
|
|
|
@ -34,7 +34,7 @@ void main() {
|
|||
final step = StepDefinitionMock(StepDefinitionConfiguration(), 2);
|
||||
expect(
|
||||
() async => await step.run(
|
||||
null, null, Duration(seconds: 1), const Iterable.empty()),
|
||||
null, null, const Duration(seconds: 1), const Iterable.empty()),
|
||||
throwsA((e) =>
|
||||
e is GherkinStepParameterMismatchException &&
|
||||
e.message ==
|
||||
|
@ -48,7 +48,8 @@ void main() {
|
|||
() async {
|
||||
final step = StepDefinitionMock(StepDefinitionConfiguration(), 2);
|
||||
expect(
|
||||
() async => await step.run(null, null, Duration(seconds: 1), [1]),
|
||||
() async =>
|
||||
await step.run(null, null, const Duration(seconds: 1), [1]),
|
||||
throwsA((e) =>
|
||||
e is GherkinStepParameterMismatchException &&
|
||||
e.message ==
|
||||
|
@ -59,7 +60,7 @@ void main() {
|
|||
|
||||
test("runs step when correct number of parameters provided", () async {
|
||||
final step = StepDefinitionMock(StepDefinitionConfiguration(), 1);
|
||||
await step.run(null, null, Duration(seconds: 1), [1]);
|
||||
await step.run(null, null, const Duration(seconds: 1), [1]);
|
||||
expect(step.invocationCount, 1);
|
||||
});
|
||||
});
|
||||
|
@ -70,9 +71,8 @@ void main() {
|
|||
final step = StepDefinitionMock(
|
||||
StepDefinitionConfiguration(), 0, () async => throw Exception("1"));
|
||||
expect(
|
||||
await step.run(
|
||||
null, null, Duration(milliseconds: 1), const Iterable.empty()),
|
||||
(r) {
|
||||
await step.run(null, null, const Duration(milliseconds: 1),
|
||||
const Iterable.empty()), (r) {
|
||||
return r is ErroredStepResult &&
|
||||
r.result == StepExecutionResult.error &&
|
||||
r.exception is Exception &&
|
||||
|
@ -86,9 +86,8 @@ void main() {
|
|||
final step = StepDefinitionMock(StepDefinitionConfiguration(), 0,
|
||||
() async => throw TestFailure("1"));
|
||||
expect(
|
||||
await step.run(
|
||||
null, null, Duration(milliseconds: 1), const Iterable.empty()),
|
||||
(r) {
|
||||
await step.run(null, null, const Duration(milliseconds: 1),
|
||||
const Iterable.empty()), (r) {
|
||||
return r is StepResult &&
|
||||
r.result == StepExecutionResult.fail &&
|
||||
r.resultReason == "1";
|
||||
|
|
Loading…
Reference in New Issue