mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-07-31 17:38:28 +00:00
[ACA-4100] use ADF user info component (#1762)
* use adf user info * delete old unit test * remove e2e * fix lint
This commit is contained in:
@@ -721,68 +721,6 @@ describe('AppExtensionService', () => {
|
||||
});
|
||||
});
|
||||
|
||||
describe('userActions', () => {
|
||||
it('should load user actions from the config', () => {
|
||||
applyConfig({
|
||||
$id: 'test',
|
||||
$name: 'test',
|
||||
$version: '1.0.0',
|
||||
$license: 'MIT',
|
||||
$vendor: 'Good company',
|
||||
$runtime: '1.5.0',
|
||||
features: {
|
||||
userActions: [
|
||||
{
|
||||
id: 'aca:toolbar/separator-1',
|
||||
order: 1,
|
||||
type: ContentActionType.separator,
|
||||
title: 'action1'
|
||||
},
|
||||
{
|
||||
id: 'aca:toolbar/separator-2',
|
||||
order: 2,
|
||||
type: ContentActionType.separator,
|
||||
title: 'action2'
|
||||
}
|
||||
]
|
||||
}
|
||||
});
|
||||
|
||||
expect(service.userActions.length).toBe(2);
|
||||
});
|
||||
|
||||
it('should sort user actions by order', () => {
|
||||
applyConfig({
|
||||
$id: 'test',
|
||||
$name: 'test',
|
||||
$version: '1.0.0',
|
||||
$license: 'MIT',
|
||||
$vendor: 'Good company',
|
||||
$runtime: '1.5.0',
|
||||
features: {
|
||||
userActions: [
|
||||
{
|
||||
id: 'aca:toolbar/action-2',
|
||||
order: 2,
|
||||
type: ContentActionType.button,
|
||||
title: 'action2'
|
||||
},
|
||||
{
|
||||
id: 'aca:toolbar/action-1',
|
||||
order: 1,
|
||||
type: ContentActionType.button,
|
||||
title: 'action1'
|
||||
}
|
||||
]
|
||||
}
|
||||
});
|
||||
|
||||
const actions = service.getUserActions();
|
||||
expect(actions[0].id).toBe('aca:toolbar/action-1');
|
||||
expect(actions[1].id).toBe('aca:toolbar/action-2');
|
||||
});
|
||||
});
|
||||
|
||||
describe('getHeaderActions', () => {
|
||||
it('should load user actions from the config', () => {
|
||||
applyConfig({
|
||||
|
Reference in New Issue
Block a user