testStore<T extends CacheStore> function Null safety

void testStore<T extends CacheStore>(
  1. TestContextBuilder<T> newTestContext,
  2. {Map<TypeTest, Function>? types,
  3. Set<StoreTest> tests = _storeTests}
)

Default store test

  • newTestContext: The context builder
  • types: The type/generator map
  • tests: The test set

Implementation

void testStore<T extends CacheStore>(TestContextBuilder<T> newTestContext,
    {Map<TypeTest, Function>? types, Set<StoreTest> tests = _storeTests}) {
  for (var entry in (types ?? _storeTypeTests).entries) {
    test('Store: ${EnumToString.convertToString(entry.key)}', () async {
      await testStoreWith<T>(newTestContext(entry.value()), tests: tests);
    });
  }
}