Fix backup restore settings and ordering
Apply restored eviction and list sorting settings before reloading data; stabilize the message-filter ingestion test against queued review history.
This commit is contained in:
1 parent
c0702806de
commit
37bfdd47fe
7 files changed
+94
No files matched your search
@@ -259,6 +259,19 @@ void main() {
|
||||
},
|
||||
);
|
||||
|
||||
test('reloads a restored custom channel order', () async {
|
||||
await _connect(_TestRadio());
|
||||
final restoredOrder = [_id(_psk(1)), _id(_psk(0)), _id(_psk(2))];
|
||||
await PrefsManager.instance.setString(
|
||||
'channel_order_$_scope',
|
||||
jsonEncode(restoredOrder),
|
||||
);
|
||||
|
||||
await _connector.reloadChannelOrder();
|
||||
|
||||
expect(_connector.channels.first.storageId, restoredOrder.first);
|
||||
});
|
||||
|
||||
test('deleting a channel clears its stored history', () async {
|
||||
await _connect(_TestRadio());
|
||||
await _waitFor(() => _texts(1).contains(_queuedHikingText));
|
||||
|
||||
@@ -410,6 +410,11 @@ void main() {
|
||||
|
||||
test('mesh copies of one message are stored and filtered once', () async {
|
||||
await _connect();
|
||||
await _waitFor(
|
||||
() => ReviewScript.seedChannelMessages.every(
|
||||
(message) => _find(message.channelIndex, message.text) != null,
|
||||
),
|
||||
);
|
||||
const text = 'Weather net starts at seven tonight on the hill';
|
||||
final ts = _nowSecs();
|
||||
final cleanBefore = _filter.recentCleanCount;
|
||||
|
||||
Reference in new issue
Block a user