Align saved video actions and confirm storage removal

This commit is contained in:
Jonathan Sykes
2026-10-03 16:10:46 +08:00
parent cf9b6f4133
commit ca836e0cd2
8 changed files with 143 additions and 18 deletions

View File

@@ -0,0 +1,11 @@
const test = require('node:test');
const assert = require('node:assert/strict');
const { matches } = require('./saved-page.js');
test('saved filtering matches title and channel without changing the library', () => {
const video = { id: 'one', title: 'A quiet morning', channel: 'Studio sessions' };
assert.equal(matches(video, 'QUIET'), true);
assert.equal(matches(video, 'studio'), true);
assert.equal(matches(video, 'evening'), false);
assert.equal(matches({ id: 'unknown' }, 'unknown'), true);
assert.equal(matches(video, ''), true);
});