This is how it is described in the official documentation.
class MyNotifier extends Notifier<int> {
@override
int build() => throw UnimplementedError();
}
// Your mock needs to subclass the Notifier base-class corresponding
// to whatever your notifier uses
class MyNotifierMock extends Notifier<int> with Mock implements MyNotifier {}
But I don't know how to use this. How can I set the status?
Maybe you can use Mock Notifier like this:
MyNotifier's state is int type state,
you can use Mock Notifier when you write test code about your riverPod Notifier codes,
please ref under these codes: