mirror of
https://github.com/nasa/openmct.git
synced 2025-02-01 00:45:41 +00:00
add output format test
This commit is contained in:
parent
b251fde1fc
commit
89e18d482d
@ -76,5 +76,18 @@ test.describe('Comps', () => {
|
||||
expect(testValue).not.toBe('10');
|
||||
// should be a number
|
||||
expect(parseFloat(testValue)).not.toBeNaN();
|
||||
|
||||
// Check that output format can be changed
|
||||
await page.getByLabel('Edit Object').click();
|
||||
await page.getByRole('tab', { name: 'Config' }).click();
|
||||
await page.getByLabel('Output Format').click();
|
||||
await page.getByLabel('Output Format').fill('%d');
|
||||
await page.getByRole('tab', { name: 'Config' }).click();
|
||||
// Ensure we only have one digit
|
||||
await expect(page.getByLabel('Current Output Value')).toHaveText(/^-1$|^0$|^1$/);
|
||||
// And that it persists post save
|
||||
await page.getByLabel('Save').click();
|
||||
await page.getByRole('listitem', { name: 'Save and Finish Editing' }).click();
|
||||
await expect(page.getByLabel('Current Output Value')).toHaveText(/^-1$|^0$|^1$/);
|
||||
});
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user