fix is-renote tests
This commit is contained in:
parent
d3792ab201
commit
fa687ecb33
|
@ -89,20 +89,19 @@ describe('misc:is-renote', () => {
|
||||||
|
|
||||||
describe('isPureRenote', () => {
|
describe('isPureRenote', () => {
|
||||||
it('should return true when note is pure renote', () => {
|
it('should return true when note is pure renote', () => {
|
||||||
const note = new MiNote({ renoteId: 'abc123' });
|
const note = new MiNote({ renoteId: 'abc123', fileIds: [] });
|
||||||
const result = isPureRenote(note);
|
const result = isPureRenote(note);
|
||||||
expect(result).toBeTruthy();
|
expect(result).toBeTruthy();
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should return false when note is quote', () => {
|
it('should return false when note is quote', () => {
|
||||||
const note = new MiNote({ renoteId: 'abc123', text: 'text' });
|
const note = new MiNote({ renoteId: 'abc123', text: 'text', fileIds: [] });
|
||||||
const result = isPureRenote(note);
|
const result = isPureRenote(note);
|
||||||
expect(result).toBeFalsy();
|
expect(result).toBeFalsy();
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should return false when note is not renote', () => {
|
it('should return false when note is not renote', () => {
|
||||||
const note = new MiNote({ renoteId: null });
|
const note = new MiNote({ renoteId: null, fileIds: [] });
|
||||||
const result = isPureRenote(note);
|
const result = isPureRenote(note);
|
||||||
expect(result).toBeFalsy();
|
expect(result).toBeFalsy();
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue