mirror of
https://github.com/nasa/openmct.git
synced 2025-03-23 04:25:27 +00:00
test: fix some existing tests
This commit is contained in:
parent
398731ad1b
commit
e489b10d74
@ -75,7 +75,7 @@ describe('The User Indicator plugin', () => {
|
||||
it('exists', () => {
|
||||
userIndicator = openmct.indicators.indicatorObjects.find(
|
||||
(indicator) => indicator.key === 'user-indicator'
|
||||
).element;
|
||||
).component;
|
||||
|
||||
const hasClockIndicator = userIndicator !== null && userIndicator !== undefined;
|
||||
expect(hasClockIndicator).toBe(true);
|
||||
@ -89,9 +89,11 @@ describe('The User Indicator plugin', () => {
|
||||
|
||||
userIndicator = openmct.indicators.indicatorObjects.find(
|
||||
(indicator) => indicator.key === 'user-indicator'
|
||||
).element;
|
||||
).component;
|
||||
|
||||
const userName = userIndicator.textContent.trim();
|
||||
expect(userIndicator).toBeDefined();
|
||||
expect(userIndicator).not.toBeNull();
|
||||
const userName = document.querySelector('[aria-label="User Role"]').textContent.trim();
|
||||
|
||||
expect(user.name).toEqual(USERNAME);
|
||||
expect(userName).toContain(USERNAME);
|
||||
|
Loading…
x
Reference in New Issue
Block a user