Skip to content

Commit 2f713ec

Browse files
committed
test(remote_config): verify #setDefaults checks for argument type
1 parent 9af633c commit 2f713ec

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

packages/firebase_remote_config/firebase_remote_config/test/firebase_remote_config_test.dart

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,15 @@ void main() {
213213
remoteConfig.setDefaults(mockParameters);
214214
verify(mockRemoteConfigPlatform.setDefaults(mockDefaultParameters));
215215
});
216+
217+
test('should throw when non-primitive value is passed', () {
218+
expect(
219+
() => remoteConfig.setDefaults({
220+
'key': {'nested': 'object'}
221+
}),
222+
throwsException,
223+
);
224+
});
216225
});
217226
});
218227
}

0 commit comments

Comments
 (0)