NotifierTester<N extends BaseSyncNotifier<T>, T> constructor

NotifierTester<N extends BaseSyncNotifier<T>, T>({
  1. required N notifier,
  2. T? initialState,
})

Implementation

NotifierTester({
  required this.notifier,
  T? initialState,
}) {
  notifier.internalSetup(
    ProxyRef(
      RefenaContainer(),
      'NotifierTester',
      LabeledReference.custom('NotifierTester'),
    ),
    null,
  );
  if (initialState != null) {
    notifier._state = initialState;
  } else {
    notifier._state = notifier.init();
  }
  notifier.postInit();
}