mirror of
https://github.com/immich-app/immich
synced 2025-10-17 18:19:27 +00:00
add async to put func call in test that was missing it
This commit is contained in:
parent
3f49cb0960
commit
aa93858e23
1 changed files with 7 additions and 9 deletions
|
|
@ -16,7 +16,6 @@ void main() {
|
||||||
await StoreService.init(storeRepository: IsarStoreRepository(db));
|
await StoreService.init(storeRepository: IsarStoreRepository(db));
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
||||||
group('sanitizeUrl', () {
|
group('sanitizeUrl', () {
|
||||||
test('Should encode correctly', () {
|
test('Should encode correctly', () {
|
||||||
var unEncodedURL = 'user:password@example.com/addSchemaAndRemovesSlashes////';
|
var unEncodedURL = 'user:password@example.com/addSchemaAndRemovesSlashes////';
|
||||||
|
|
@ -47,7 +46,7 @@ void main() {
|
||||||
});
|
});
|
||||||
|
|
||||||
group('punycodeDecode', () {
|
group('punycodeDecode', () {
|
||||||
test('malformed URL returns a null', () {
|
test('malformed URL returns a null', () {
|
||||||
var badURL = 'example.com/missing%20a%20scheme';
|
var badURL = 'example.com/missing%20a%20scheme';
|
||||||
expect(punycodeDecodeUrl(badURL), null);
|
expect(punycodeDecodeUrl(badURL), null);
|
||||||
});
|
});
|
||||||
|
|
@ -68,8 +67,8 @@ void main() {
|
||||||
expect(getServerUrl(), null);
|
expect(getServerUrl(), null);
|
||||||
});
|
});
|
||||||
|
|
||||||
test('Returns null if what was set is not a correct url', () {
|
test('Returns null if what was set is not a correct url', () async {
|
||||||
Store.put(StoreKey.serverEndpoint, 'example.com');
|
await Store.put(StoreKey.serverEndpoint, 'example.com');
|
||||||
expect(getServerUrl(), null);
|
expect(getServerUrl(), null);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
@ -91,11 +90,10 @@ void main() {
|
||||||
expect(getServerUrl(), portURL);
|
expect(getServerUrl(), portURL);
|
||||||
});
|
});
|
||||||
|
|
||||||
test('Returns decoded complex URL', () async {
|
test('Returns decoded complex URL', () async {
|
||||||
var complexURL = 'https://user:password@example.com:1337/123/abc';
|
var complexURL = 'https://user:password@example.com:1337/123/abc';
|
||||||
await Store.put(StoreKey.serverEndpoint, complexURL);
|
await Store.put(StoreKey.serverEndpoint, complexURL);
|
||||||
expect(getServerUrl(), 'https://user:password@example.com:1337');
|
expect(getServerUrl(), 'https://user:password@example.com:1337');
|
||||||
});
|
});
|
||||||
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue