Upload corporate logo (#1314)

* feat: upload logo to project data

---------

Co-authored-by: Carlos Valente <carlosvalente@pm.me>
This commit is contained in:
Ary
2024-11-17 14:55:20 -07:00
committed by GitHub
parent 8dd448db44
commit a6e1cbbbce
26 changed files with 289 additions and 13 deletions
@@ -60,6 +60,34 @@ describe('parseProject()', () => {
expect(result).toBeTypeOf('object');
expect(errorEmitter).toHaveBeenCalledOnce();
});
it('test migration with adding the logo field v3.8.0', () => {
const errorEmitter = vi.fn();
const result = parseProject(
{
//@ts-expect-error -- checking migration when the logo field is added
project: {
title: 'title',
description: 'description',
publicUrl: 'publicUrl',
publicInfo: 'publicInfo',
backstageUrl: 'backstageUrl',
backstageInfo: 'backstageInfo',
},
},
errorEmitter,
);
expect(result).toStrictEqual({
title: 'title',
description: 'description',
publicUrl: 'publicUrl',
publicInfo: 'publicInfo',
backstageUrl: 'backstageUrl',
backstageInfo: 'backstageInfo',
projectLogo: null,
});
expect(errorEmitter).not.toHaveBeenCalled();
});
});
describe('parseSettings()', () => {