chore(formatting): ran formatter
This commit is contained in:
parent
fc5e7b8832
commit
2ccdb80a29
|
@ -6,8 +6,7 @@ class AggregatedHook extends Hook {
|
|||
Iterable<Hook> _orderedHooks;
|
||||
|
||||
void addHooks(Iterable<Hook> hooks) {
|
||||
_orderedHooks = hooks.toList()
|
||||
..sort((a, b) => b.priority - a.priority);
|
||||
_orderedHooks = hooks.toList()..sort((a, b) => b.priority - a.priority);
|
||||
}
|
||||
|
||||
Future<void> onBeforeRun(TestConfiguration config) async =>
|
||||
|
@ -17,19 +16,18 @@ class AggregatedHook extends Hook {
|
|||
Future<void> onAfterRun(TestConfiguration config) async =>
|
||||
await _invokeHooks((h) => h.onAfterRun(config));
|
||||
|
||||
Future<void> onAfterScenarioWorldCreated(World world,
|
||||
String scenario) async =>
|
||||
await _invokeHooks((h) =>
|
||||
h.onAfterScenarioWorldCreated(world, scenario));
|
||||
Future<void> onAfterScenarioWorldCreated(
|
||||
World world, String scenario) async =>
|
||||
await _invokeHooks((h) => h.onAfterScenarioWorldCreated(world, scenario));
|
||||
|
||||
/// Run before a scenario and it steps are executed
|
||||
Future<void> onBeforeScenario(TestConfiguration config,
|
||||
String scenario) async =>
|
||||
Future<void> onBeforeScenario(
|
||||
TestConfiguration config, String scenario) async =>
|
||||
await _invokeHooks((h) => h.onBeforeScenario(config, scenario));
|
||||
|
||||
/// Run after a scenario has executed
|
||||
Future<void> onAfterScenario(TestConfiguration config,
|
||||
String scenario) async =>
|
||||
Future<void> onAfterScenario(
|
||||
TestConfiguration config, String scenario) async =>
|
||||
await _invokeHooks((h) => h.onAfterScenario(config, scenario));
|
||||
|
||||
Future<void> _invokeHooks(Future<void> invoke(Hook h)) async {
|
||||
|
|
|
@ -8,7 +8,8 @@ class MockStepDefinition extends StepDefinitionBase<World, Function> {
|
|||
int runCount = 0;
|
||||
final OnRunCode code;
|
||||
|
||||
MockStepDefinition([this.code, int expectedParameterCount = 0]) : super(null, expectedParameterCount);
|
||||
MockStepDefinition([this.code, int expectedParameterCount = 0])
|
||||
: super(null, expectedParameterCount);
|
||||
|
||||
@override
|
||||
Future<void> onRun(Iterable parameters) async {
|
||||
|
|
Loading…
Reference in New Issue