Skip to content

Commit

Permalink
Remove dispose method on testclass param
Browse files Browse the repository at this point in the history
  • Loading branch information
ArtAhmetaj committed Oct 28, 2024
1 parent 06525e8 commit d118a07
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions test/get_it_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,6 @@ class TestClassParam extends TestBaseClass {
TestClassParam({this.param1, this.param2}) {
constructorCounter++;
}

void dispose() {
disposeCounter++;
}
}

class TestClassDisposableWithDependency with Disposable {
Expand Down Expand Up @@ -268,7 +264,7 @@ void main() {
final getIt = GetIt.instance;
constructorCounter = 0;
getIt.registerCachedFactoryParam<TestClassParam, String, int>(
(f,s) => TestClassParam(param1: f,param2:s),
(f, s) => TestClassParam(param1: f, param2: s),
);
final instance1 = getIt<TestClassParam>(param1: 'abc', param2: 1);
final instance2 = getIt<TestClassParam>(param1: 'abc', param2: 1);
Expand All @@ -282,7 +278,7 @@ void main() {
final getIt = GetIt.instance;
constructorCounter = 0;
getIt.registerCachedFactoryParam<TestClassParam, String, int>(
(f,s) => TestClassParam(param1: f,param2: s),
(f, s) => TestClassParam(param1: f, param2: s),
);
final instance1 = getIt<TestClassParam>(param1: 'abc', param2: 1);
final instance2 = getIt<TestClassParam>(param1: 'abc', param2: 2);
Expand Down

0 comments on commit d118a07

Please sign in to comment.