You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-11-29 22:48:10 +02:00
Desktop: Add support for multiple columns note list (#9924)
This commit is contained in:
31
packages/utils/object.test.ts
Normal file
31
packages/utils/object.test.ts
Normal file
@@ -0,0 +1,31 @@
|
||||
import { objectValueFromPath } from './object';
|
||||
|
||||
describe('object', () => {
|
||||
|
||||
test.each([
|
||||
[
|
||||
{
|
||||
note: {
|
||||
id: '123',
|
||||
title: 'my note',
|
||||
},
|
||||
},
|
||||
'note.title',
|
||||
'my note',
|
||||
],
|
||||
[
|
||||
{
|
||||
note: {
|
||||
id: '123',
|
||||
title: 'my note',
|
||||
},
|
||||
},
|
||||
'note.doesntexist',
|
||||
undefined,
|
||||
],
|
||||
])('should extract URLs', (object, path, expected) => {
|
||||
const actual = objectValueFromPath(object, path);
|
||||
expect(actual).toBe(expected);
|
||||
});
|
||||
|
||||
});
|
||||
Reference in New Issue
Block a user