mockito icon indicating copy to clipboard operation
mockito copied to clipboard

Mockito-inspired mock library for Dart

Results 76 mockito issues
Sort by recently updated
recently updated
newest added

Bumps the github-actions group with 2 updates in the / directory: [actions/stale](https://github.com/actions/stale) and [dart-lang/setup-dart](https://github.com/dart-lang/setup-dart). Updates `actions/stale` from 9.0.0 to 9.1.0 Release notes Sourced from actions/stale's releases. v9.1.0 What's Changed Documentation...

Fixes #801 Have the generator correctly generate dummy return value for `Future` Before, the generators would return: `_i2.Future.value((0))` (which won't compile). After, it will generate a cast from the representation...

```dart import 'package:mockito/annotations.dart'; class Foo { Future bar() async => Id(0); } extension type Id(int id) {} @GenerateNiceMocks([MockSpec()]) class Test {} ``` Will generate ```dart class MockFoo extends _i1.Mock implements...

```dart @AutoRouterConfig( replaceInRouteName: 'Page,Route,Screen', ) ``````dart class MainRouter extends RootStackRouter { } ``` `class TestRouter extends Mock implements MainRouter, RootStackRouter {}` `MockSpec(as: Symbol('MockTestRouter'), onMissingStub: OnMissingStub.returnDefault),` Error: ```dart [SEVERE] mockito:mockBuilder on...

At the start of the generated mock files, Mockito puts a `// ignore_for_file: must_be_immutable` directive. For immutable classes Mockito additionally puts another `// ignore: must_be_immutable`. This generates the following analyzer...

type-bug

The README fails to mention a common use case that is an exception to the behavior described around `GeneratedMocks`. This PR updates the readme with a link to the issue...