Fixes #273. Also fixes: - Weird (wrong) serialization of the hash maps - An issue with migrations when passing a const list NOTE: If you ran Moxxy between the merge of #267 and this commit, you have to remove Moxxy's data and start anew.
19 lines
431 B
Dart
19 lines
431 B
Dart
import 'package:moxxmpp/moxxmpp.dart';
|
|
import 'package:moxxyv2/shared/models/file_metadata.dart';
|
|
import 'package:test/test.dart';
|
|
|
|
void main() {
|
|
test('Test serializing and deserializing hash maps', () {
|
|
final map = {
|
|
HashFunction.sha256: 'hash1',
|
|
HashFunction.sha512: 'hash2',
|
|
HashFunction.blake2b512: 'hash3',
|
|
};
|
|
|
|
expect(
|
|
deserializeHashMap(serializeHashMap(map)),
|
|
map,
|
|
);
|
|
});
|
|
}
|