mirror of
https://github.com/Alfresco/alfresco-content-app.git
synced 2025-07-24 17:31:52 +00:00
tests
This commit is contained in:
@@ -439,4 +439,40 @@ describe('app.evaluators', () => {
|
||||
expect(app.isShared(context)).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
describe('canShowLanguagePicker', () => {
|
||||
it('should return true when property is true', () => {
|
||||
const context: any = {
|
||||
languagePicker: true
|
||||
};
|
||||
|
||||
expect(app.canShowLanguagePicker(context)).toBe(true);
|
||||
});
|
||||
|
||||
it('should return false when property is false', () => {
|
||||
const context: any = {
|
||||
languagePicker: false
|
||||
};
|
||||
|
||||
expect(app.canShowLanguagePicker(context)).toBe(false);
|
||||
});
|
||||
});
|
||||
|
||||
describe('canShowLogout', () => {
|
||||
it('should return false when `withCredentials` property is true', () => {
|
||||
const context: any = {
|
||||
withCredentials: true
|
||||
};
|
||||
|
||||
expect(app.canShowLogout(context)).toBe(false);
|
||||
});
|
||||
|
||||
it('should return true when `withCredentials` property is false', () => {
|
||||
const context: any = {
|
||||
withCredentials: false
|
||||
};
|
||||
|
||||
expect(app.canShowLanguagePicker(context)).toBe(true);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
Reference in New Issue
Block a user