2022-03-23 21:10:50 +00:00
/ * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Open MCT , Copyright ( c ) 2014 - 2023 , United States Government
* as represented by the Administrator of the National Aeronautics and Space
* Administration . All rights reserved .
*
* Open MCT is licensed under the Apache License , Version 2.0 ( the
* "License" ) ; you may not use this file except in compliance with the License .
* You may obtain a copy of the License at
* http : //www.apache.org/licenses/LICENSE-2.0.
*
* Unless required by applicable law or agreed to in writing , software
* distributed under the License is distributed on an "AS IS" BASIS , WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND , either express or implied . See the
* License for the specific language governing permissions and limitations
* under the License .
*
* Open MCT includes source code licensed under additional open source
* licenses . See the Open Source Licenses file ( LICENSES . md ) included with
* this source code distribution or the Licensing information page available
* at runtime from the About dialog for additional information .
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * /
/ *
This test suite is dedicated to tests which verify the basic operations surrounding imagery ,
but only assume that example imagery is present .
* /
2022-05-03 17:18:06 +00:00
/* globals process */
2022-07-27 21:31:18 +00:00
const { waitForAnimations } = require ( '../../../../baseFixtures' ) ;
const { test , expect } = require ( '../../../../pluginFixtures' ) ;
2023-07-28 02:06:41 +00:00
const { createDomainObjectWithDefaults , setRealTimeMode } = require ( '../../../../appActions' ) ;
2022-06-30 18:50:47 +00:00
const backgroundImageSelector = '.c-imagery__main-image__background-image' ;
2023-03-15 03:42:31 +00:00
const panHotkey = process . platform === 'linux' ? [ 'Shift' , 'Alt' ] : [ 'Alt' ] ;
2023-06-20 17:12:45 +00:00
const tagHotkey = [ 'Shift' , 'Alt' ] ;
2023-03-15 03:42:31 +00:00
const expectedAltText = process . platform === 'linux' ? 'Shift+Alt drag to pan' : 'Alt drag to pan' ;
2023-01-21 19:25:35 +00:00
const thumbnailUrlParamsRegexp = /\?w=100&h=100/ ;
2022-06-30 18:50:47 +00:00
2.0.5 Backmerge (#5505)
* Bump d3-selection from 1.3.2 to 3.0.0
Bumps [d3-selection](https://github.com/d3/d3-selection) from 1.3.2 to 3.0.0.
- [Release notes](https://github.com/d3/d3-selection/releases)
- [Commits](https://github.com/d3/d3-selection/compare/v1.3.2...v3.0.0)
---
updated-dependencies:
- dependency-name: d3-selection
dependency-type: direct:development
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
* Remove snapshot
* Fix imagery filter slider drag in flexible layouts (#5326) (#5350)
* Dont' mutate a stacked plot unless its user initiated (#5357)
* Port grid icons and imagery test to release 2.0.5 from master (#5360)
* Port grid icons to release 2.0.5 from master
* Port imagery test to release/2.0.5
* Restrict timestrip composition to time based plots, plans and imagery (#5161)
* Restrict timestrip composition to time based plots, plans and imagery
* Adds unit tests for timeline composition policy
* Addresses review comments
Improves tests
* Reuse test objects
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
* Include objectStyles reference to conditionSetIdentifier in imports (#5354)
* Include objectStyles reference to conditionSetIdentifier in imports
* Add tests for export
* Refactored some code and removed console log
* Remove workarounds for chrome 'scrollTop' issue (#5375)
* Fix naming of method (#5368)
* Imagery View does not discard old images when they fall out of bounds (#5351)
* change to using telemetry collection
* fix tests
* added more unit tests
* Cherrypicked commits (#5390)
Co-authored-by: unlikelyzero <jchill2@gmail.com>
* [Timer] Update 3dot menu actions appropriately (#5387)
* Call `removeAllListeners()` after emit
* Manually show/hide actions if within a view
* remove sneaky `console.log()`
* Add Timer e2e test
* Add to comments
* Avoid hard waits in Timer e2e test
- Assert against timer view state instead of menu options
* Let's also test actions from the Timer view
* 5391 Add preview and drag support to Grand Search (#5394)
* add preview and drag actions
* added unit test, simplified remove action
* do not hide search results in preview mode when clicking outside search results
* add semantic aria labels to enable e2e tests
* readd preview
* add e2e test
* remove commented out url
* add percy snapshot and add search to ci
* make percy stuff work
* linting
* fix percy again
* move percy snapshots to a visual test
* added separate visual test and changed test to fixtures
* fix fixtures path
* addressing review comments
* 5361 tags not persisting locally (#5408)
* fixed typo
* remove unneeded lookup
* fix tags adding and deleting
* more reliable way to remove tags
* break tests up for parallel execution
* fixed notebook tagging test
* enable e2e tests
* made schedule index comment more clear and fix uppercase/lowercase issue
* address e2e changes
* add unit test to bump coverage
* fix typo
* need to check on annotation creation if provider exists or not
* added fixtures
* undo silly couchdb commit
* Plot progress bar fix for 2.0.5 (#5386)
* Add .bind(this) to stopLoading() in loadMoreData()
* Replace load spinner with progress bar for plots
* Add loading delay prop to swg
* fix linting errors
* match load order
* Update accessibility
* Add Math.max to timeout to handle negative inputs
* Moved math.max to load delay variable
* Add loading fix for stacked plots
* Move loadingUpdate func into plot item for update
* Merge conflict resolve
* Check if delay is 0 and send, put post in a func
* Put obj directly to model, removed computed prop
* Lint fix
* Fix template where legend was not displayed
* Remove commented out template
* Fixed failing test
Co-authored-by: unlikelyzero <jchill2@gmail.com>
* Make plans non editable. (#5377)
* Make plans non editable.
* Add unit test for fix
* [CouchDB] Better determination of indicator status (#5415)
* Add unknown state, remove maintenance state
* Handle all CouchDB status codes
- Set unknown status if we receive an unhandled code
* Include status code in error messages
* SharedWorker can send unknown status
* Add test for unknown status
* Gauge fixes for Firefox and units display (#5369)
* Closes #5323, #5325. Parent branch is release/2.0.5.
- Significant work refactoring SVG markup and CSS for dial gauge;
- Fixed missing `v-if` to control display of units for #5325;
- Fixed bad `.length` test for limit properties;
* Closes #5323, #5325
- Add 'value out of range' indicator
* Closes #5323, #5325
- More accurate element naming;
- Fix cross-browser problems with current value display in dial gauge;
- Refinements to "out of range" indicator approach;
- Fixed size of "Amplitude" input in Sine Wave Generator;
* Closes #5323, #5325
- Styles and stubbed in code to support needle meter type;
* Closes #5323, #5325
- Stubbed in markup and CSS for needle-style meter;
* Closes #5323, #5325
- Fixed missing `js-*` classes that were failing npm run test;
* Closes #5323, #5325
- Fix to not display meter value bar unless a data value is expected;
* Addressing PR comments
- Renamed method for clarity;
- Added null value check in method `valueExpected`;
* [Static Root] Return leafValue if null/undefined/false (#5416)
* Return leafValue if null/undefined/false
* Added a null to the test json
* Show a better default poll question (#5425)
* 5361 Tags not persisting when several notebook entries are created at once (#5428)
* add end to end test to catch multiple entry errors
* click expansion triangle instead
* fix race condition between annotation creation and mutation
* make sure notebook tags run in e2e
* address PR comments
* Handle missing objects gracefully (#5399)
* Handle missing object errors for display layouts
* Handle missing object errors for Overlay Plots
* Add check for this.config
* Add try/catch statement & check if obj is missing
* Changed console.error to console.warn
* Lint fix
* Fix for this.metadata.value is undefined
* Add e2e test
* Update comment text
* Add reload check and @private, verify console.warn
* Redid assignment and metadata check
* Fix typo
* Changed assignment and metadata check
* Redid checks for isMissing(object)
* Lint fix
* Backmerge e2e code coverage changes and fixes into release/2.0.5 (#5431)
* [Telemetry Collections] Respect "Latest" Strategy Option (#5421)
* Respect latest strategy in Telemetry Collections to limit potential memory growth.
* fix sourcemaps (#5373)
Co-authored-by: John Hill <john.c.hill@nasa.gov>
* Debounce status summary (#5448)
Co-authored-by: John Hill <john.c.hill@nasa.gov>
* No gauge (#5451)
* Installed gauge plugin by default
* Make gauge part of standard install in e2e suite and add restrictednotebook
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* [CouchDB] Always subscribe to the CouchDB changes feed (#5434)
* Add unknown state, remove maintenance state
* Handle all CouchDB status codes
- Set unknown status if we receive an unhandled code
* Include status code in error messages
* SharedWorker can send unknown status
* Add test for unknown status
* Always subscribe to CouchDB changes feed
- Always subscribe to the CouchDB changes feed, even if there are no observable objects, since we are also checking the status of CouchDB via this feed.
* Update indicator status if not using SharedWorker
* Start listening to changes feed on first request
* fix test
* adjust test to hopefully avoid race condition
* lint
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
* Fix for Fault Management Visual Bugs (#5376)
* Closes #5365
* General visual improvements
Co-authored-by: Charles Hacskaylo <charlesh88@gmail.com>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* fix pathing (#5452)
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* [Static Root] Static Root Plugin not loading (#5455)
* Log if hitting falsy leafValue
* Add some logging
* Remove logs and specify null/undefined
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* Allow endpoints with a single enum metadata value in Bar/Line graphs (#5443)
* If there is only 1 metadata value, set yKey to none. Also, fix bug for determining the name of a metadata value
* Update tests for enum metadata values
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* [Remote Clock] Wait for first tick and recalculate historical request bounds (#5433)
* Updated to ES6 class
* added request intercept functionality to telemetry api, added a request interceptor for remote clock
* add remoteClock e2e test stub
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Fix for missing object for LADTableSet (#5458)
* Handle missing object errors for display layouts
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* removing the call for default import now that TelemetryAPI is an ES6 class (#5461)
* [Remote Clock] Fix requestInterceptor typo (#5462)
* Fix typo in telemetry request interceptor
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Lock model (#5457)
* Lock event Model to prevent reactification
* de-reactify all the things
* Make API properties writable to allow test mocks to override them
* Fix merge conflict
* Added plot interceptor for missing series config (#5422)
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Shefali Joshi <simplyrender@gmail.com>
* Remove performance marks (#5465)
* Remove performance marks
* Retain performance mark in view large. It doesn't happen very often and it's needed for an automated performance test
* Use timeKey for time comparison (#5471)
* Fix couchdb no response (#5474)
* Update the creation date only when the document is created for the first time
* If there is no response from a bulk get, couch db has issues
* Check the response - if it's null, don't apply interceptors
* Fix shelved alarms (#5479)
* Fix the logic around shelved alarms
* Remove application router listener
* Release 2.0.5 UI and Gauge fixes (#5470)
* Various UI fixes
- Tweak to Gauge properties form for clarity and usability.
- Fix Gauge 'dial' type not obeying "Show units" property setting, closes #5325.
- Tweaks to Operator Status UI label and layout for clarity.
- Changed name and description of Graph object for clarity and consistency.
- Fixed CSS classing that was coloring Export menu items text incorrectly.
- Fixed icon-to-text vertical alignment in `.c-object-label`.
- Fix for broken layout in imagery local controls (brightness, layers, magnification).
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Stacked plot interceptor rename (#5468)
* Rename stacked plot interceptor and move to folder
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Clear data when time bounds are changed (#5482)
* Clear data when time bounds are changed
Also react to clear data action
Ensure that the yKey is set to 'none' if there is no range with array Values
* Refactor trace updates to a method
* get rid of root (#5483)
* Do not pass onPartialResponse option on to upstream telemetry (#5486)
* Fix all of the e2e tests (#5477)
* Fix timer test
* be explicit about the warnings text
* add full suite to CI to enable CircleCI Checks
* add back in devtool=false for CI env so firefox tests run
* add framework suite
* Don't install webpack HMR in CI
* Fix playwright version installs
* exclude HMR if running tests in any environment
- use NODE_ENV=TEST to exclude webpack HMR
- deparameterize some of the playwright configs
* use lower-case 'test'
* timer hover fix
* conditionally skip for firefox due to missing console events
* increase timeouts to give time for mutation
* no need to close save banner
* remove devtool setting
* revert
* update snapshots
* disable video to save some resources
* use one worker
* more timeouts :)
* Remove `browser.close()` and `page.close()` as it was breaking other tests
* Remove unnecessary awaits and fix func call syntax
* Fix image reset test
* fix restrictedNotebook tests
* revert playwright-ci.config settings
* increase timeout for polling imagery test
* remove unnecessary waits
* disable notebook lock test for chrome-beta as its unreliable
- remove some unnecessary 'wait for save banner' logic
- remove unused await
- mark imagery test as slow in chrome-beta
* LINT!! *shakes fist*
* don't run full e2e suite per commit
* disable video in all configs
* add flakey zoom comment
* exclude webpack HMR in non-development modes
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* lint fix
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Joshi <simplyrender@gmail.com>
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: unlikelyzero <jchill2@gmail.com>
Co-authored-by: Alize Nguyen <alizenguyen@gmail.com>
Co-authored-by: Charles Hacskaylo <charlesh88@gmail.com>
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
Co-authored-by: rukmini-bose <48999852+rukmini-bose@users.noreply.github.com>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
2022-07-14 21:52:28 +00:00
//The following block of tests verifies the basic functionality of example imagery and serves as a template for Imagery objects embedded in other objects.
2022-06-30 18:50:47 +00:00
test . describe ( 'Example Imagery Object' , ( ) => {
2022-03-23 21:10:50 +00:00
test . beforeEach ( async ( { page } ) => {
//Go to baseURL
2023-04-18 22:32:29 +00:00
await page . goto ( './' , { waitUntil : 'domcontentloaded' } ) ;
2022-03-23 21:10:50 +00:00
2022-07-29 23:50:40 +00:00
// Create a default 'Example Imagery' object
2022-11-07 23:50:33 +00:00
const exampleImagery = await createDomainObjectWithDefaults ( page , { type : 'Example Imagery' } ) ;
2022-06-30 18:50:47 +00:00
2022-07-29 23:50:40 +00:00
// Verify that the created object is focused
2022-11-07 23:50:33 +00:00
await expect ( page . locator ( '.l-browse-bar__object-name' ) ) . toContainText ( exampleImagery . name ) ;
2023-06-20 17:12:45 +00:00
await page . locator ( '.c-imagery__main-image__bg' ) . hover ( { trial : true } ) ;
2023-07-28 02:06:41 +00:00
await page . locator ( backgroundImageSelector ) . waitFor ( ) ;
2022-03-23 21:10:50 +00:00
} ) ;
test ( 'Can use Mouse Wheel to zoom in and out of latest image' , async ( { page } ) => {
2022-09-12 16:19:24 +00:00
// Zoom in x2 and assert
await mouseZoomOnImageAndAssert ( page , 2 ) ;
2022-03-23 21:10:50 +00:00
2022-09-12 16:19:24 +00:00
// Zoom out x2 and assert
await mouseZoomOnImageAndAssert ( page , - 2 ) ;
2022-06-13 22:24:44 +00:00
} ) ;
2023-05-18 21:54:46 +00:00
2022-06-30 18:50:47 +00:00
test ( 'Can adjust image brightness/contrast by dragging the sliders' , async ( {
2023-05-18 21:54:46 +00:00
page ,
2022-08-24 19:31:26 +00:00
browserName
2023-05-18 21:54:46 +00:00
} ) => {
2022-08-24 19:31:26 +00:00
// eslint-disable-next-line playwright/no-skipped-test
test . skip ( browserName === 'firefox' , 'This test needs to be updated to work with firefox' ) ;
2022-06-13 22:24:44 +00:00
// Open the image filter menu
await page . locator ( '[role=toolbar] button[title="Brightness and contrast"]' ) . click ( ) ;
2022-06-30 18:50:47 +00:00
// Drag the brightness and contrast sliders around and assert filter values
2022-06-13 22:24:44 +00:00
await dragBrightnessSliderAndAssertFilterValues ( page ) ;
await dragContrastSliderAndAssertFilterValues ( page ) ;
2023-05-18 21:54:46 +00:00
} ) ;
2022-03-23 21:10:50 +00:00
2023-07-19 00:32:05 +00:00
test ( 'Can use independent time conductor to change time' , async ( { page } ) => {
2023-07-28 02:06:41 +00:00
test . info ( ) . annotations . push ( {
type : 'issue' ,
description : 'https://github.com/nasa/openmct/issues/6821'
} ) ;
2023-07-19 00:32:05 +00:00
// Test independent fixed time with global fixed time
// flip on independent time conductor
2023-07-28 02:06:41 +00:00
await page . getByRole ( 'switch' , { name : 'Enable Independent Time Conductor' } ) . click ( ) ;
2023-08-07 22:48:29 +00:00
// Adding in delay to address flakiness of ITC test-- button event handlers not registering in time
await expect ( page . locator ( '#independentTCToggle' ) ) . toBeChecked ( ) ;
await expect ( page . locator ( '.c-compact-tc' ) . first ( ) ) . toBeVisible ( ) ;
2023-07-28 02:06:41 +00:00
await page . getByRole ( 'button' , { name : 'Independent Time Conductor Settings' } ) . click ( ) ;
2023-08-07 22:48:29 +00:00
2023-07-28 02:06:41 +00:00
await page . getByRole ( 'textbox' , { name : 'Start date' } ) . fill ( '2021-12-30' ) ;
2023-07-31 16:57:11 +00:00
await page . keyboard . press ( 'Tab' ) ;
2023-08-07 22:48:29 +00:00
await page . getByRole ( 'textbox' , { name : 'Start time' } ) . fill ( '01:01:00' ) ;
2023-07-31 16:57:11 +00:00
await page . keyboard . press ( 'Tab' ) ;
2023-08-07 22:48:29 +00:00
await page . getByRole ( 'textbox' , { name : 'End date' } ) . fill ( '2021-12-30' ) ;
2023-07-31 16:57:11 +00:00
await page . keyboard . press ( 'Tab' ) ;
2023-08-07 22:48:29 +00:00
await page . getByRole ( 'textbox' , { name : 'End time' } ) . fill ( '01:11:00' ) ;
2023-07-31 16:57:11 +00:00
await page . keyboard . press ( 'Tab' ) ;
await page . keyboard . press ( 'Enter' ) ;
2023-07-19 00:32:05 +00:00
// check image date
2023-08-07 23:19:13 +00:00
await expect ( page . getByText ( '2021-12-30 01:01:00.000Z' ) . first ( ) ) . toBeVisible ( ) ;
2023-07-19 00:32:05 +00:00
// flip it off
2023-07-28 02:06:41 +00:00
await page . getByRole ( 'switch' , { name : 'Disable Independent Time Conductor' } ) . click ( ) ;
2023-07-19 00:32:05 +00:00
// timestamp shouldn't be in the past anymore
await expect ( page . getByText ( '2021-12-30 01:11:00.000Z' ) ) . toBeHidden ( ) ;
// Test independent fixed time with global realtime
2023-07-28 02:06:41 +00:00
await setRealTimeMode ( page ) ;
2023-08-07 22:48:29 +00:00
await expect (
page . getByRole ( 'switch' , { name : 'Enable Independent Time Conductor' } )
) . toBeEnabled ( ) ;
2023-07-28 02:06:41 +00:00
await page . getByRole ( 'switch' , { name : 'Enable Independent Time Conductor' } ) . click ( ) ;
2023-07-19 00:32:05 +00:00
// check image date to be in the past
2023-08-07 22:48:29 +00:00
await expect ( page . getByText ( '2021-12-30 01:01:00.000Z' ) . first ( ) ) . toBeVisible ( ) ;
2023-07-19 00:32:05 +00:00
// flip it off
2023-07-28 02:06:41 +00:00
await page . getByRole ( 'switch' , { name : 'Disable Independent Time Conductor' } ) . click ( ) ;
2023-07-19 00:32:05 +00:00
// timestamp shouldn't be in the past anymore
await expect ( page . getByText ( '2021-12-30 01:11:00.000Z' ) ) . toBeHidden ( ) ;
// Test independent realtime with global realtime
2023-07-28 02:06:41 +00:00
await page . getByRole ( 'switch' , { name : 'Enable Independent Time Conductor' } ) . click ( ) ;
2023-07-19 00:32:05 +00:00
// check image date
await expect ( page . getByText ( '2021-12-30 01:11:00.000Z' ) . first ( ) ) . toBeVisible ( ) ;
// change independent time to realtime
2023-07-28 02:06:41 +00:00
await page . getByRole ( 'button' , { name : 'Independent Time Conductor Settings' } ) . click ( ) ;
await page . getByRole ( 'button' , { name : 'Independent Time Conductor Mode Menu' } ) . click ( ) ;
await page . getByRole ( 'menuitem' , { name : /Real-Time/ } ) . click ( ) ;
2023-07-19 00:32:05 +00:00
// timestamp shouldn't be in the past anymore
await expect ( page . getByText ( '2021-12-30 01:11:00.000Z' ) ) . toBeHidden ( ) ;
// back to the past
2023-07-28 02:06:41 +00:00
await page . getByRole ( 'button' , { name : 'Independent Time Conductor Mode Menu' } ) . click ( ) ;
await page . getByRole ( 'menuitem' , { name : /Real-Time/ } ) . click ( ) ;
await page . getByRole ( 'button' , { name : 'Independent Time Conductor Mode Menu' } ) . click ( ) ;
2023-07-19 00:32:05 +00:00
await page . getByRole ( 'menuitem' , { name : /Fixed Timespan/ } ) . click ( ) ;
// check image date to be in the past
await expect ( page . getByText ( '2021-12-30 01:11:00.000Z' ) . first ( ) ) . toBeVisible ( ) ;
} ) ;
2022-06-13 22:24:44 +00:00
test ( 'Can use alt+drag to move around image once zoomed in' , async ( { page } ) => {
const deltaYStep = 100 ; //equivalent to 1x zoom
2022-03-23 21:10:50 +00:00
2023-06-20 17:12:45 +00:00
await page . locator ( '.c-imagery__main-image__bg' ) . hover ( { trial : true } ) ;
2022-03-23 21:10:50 +00:00
2022-07-27 21:31:18 +00:00
// zoom in
await page . mouse . wheel ( 0 , deltaYStep * 2 ) ;
2023-06-20 17:12:45 +00:00
await page . locator ( '.c-imagery__main-image__bg' ) . hover ( { trial : true } ) ;
2022-09-12 16:19:24 +00:00
const zoomedBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
const imageCenterX = zoomedBoundingBox . x + zoomedBoundingBox . width / 2 ;
2022-03-23 21:10:50 +00:00
const imageCenterY = zoomedBoundingBox . y + zoomedBoundingBox . height / 2 ;
// move to the right
2022-07-27 21:31:18 +00:00
// center the mouse pointer
2022-06-30 18:50:47 +00:00
await page . mouse . move ( imageCenterX , imageCenterY ) ;
2022-03-23 21:10:50 +00:00
2022-07-15 23:39:55 +00:00
//Get Diagnostic info about process environment
console . log ( 'process.platform is ' + process . platform ) ;
const getUA = await page . evaluate ( ( ) => navigator . userAgent ) ;
console . log ( 'navigator.userAgent ' + getUA ) ;
// Pan Imagery Hints
const imageryHintsText = await page . locator ( '.c-imagery__hints' ) . innerText ( ) ;
expect ( expectedAltText ) . toEqual ( imageryHintsText ) ;
2022-05-03 17:18:06 +00:00
2022-07-15 23:39:55 +00:00
// pan right
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . down ( x ) ) ) ;
2022-03-23 21:10:50 +00:00
await page . mouse . down ( ) ;
2022-07-15 23:39:55 +00:00
await page . mouse . move ( imageCenterX - 200 , imageCenterY , 10 ) ;
2022-03-23 21:10:50 +00:00
await page . mouse . up ( ) ;
2022-06-30 18:50:47 +00:00
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . up ( x ) ) ) ;
const afterRightPanBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
2022-03-30 21:16:59 +00:00
expect ( zoomedBoundingBox . x ) . toBeGreaterThan ( afterRightPanBoundingBox . x ) ;
2022-03-23 21:10:50 +00:00
2022-07-15 23:39:55 +00:00
// pan left
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . down ( x ) ) ) ;
await page . mouse . down ( ) ;
await page . mouse . move ( imageCenterX , imageCenterY , 10 ) ;
await page . mouse . up ( ) ;
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . up ( x ) ) ) ;
const afterLeftPanBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
expect ( afterRightPanBoundingBox . x ) . toBeLessThan ( afterLeftPanBoundingBox . x ) ;
2022-03-23 21:10:50 +00:00
// pan up
2022-05-18 01:44:16 +00:00
await page . mouse . move ( imageCenterX , imageCenterY ) ;
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . down ( x ) ) ) ;
await page . mouse . down ( ) ;
await page . mouse . move ( imageCenterX , imageCenterY + 200 , 10 ) ;
await page . mouse . up ( ) ;
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . up ( x ) ) ) ;
const afterUpPanBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
expect ( afterUpPanBoundingBox . y ) . toBeGreaterThan ( afterLeftPanBoundingBox . y ) ;
// pan down
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . down ( x ) ) ) ;
2022-03-23 21:10:50 +00:00
await page . mouse . down ( ) ;
2022-05-18 01:44:16 +00:00
await page . mouse . move ( imageCenterX , imageCenterY - 200 , 10 ) ;
2022-07-29 23:50:40 +00:00
await page . mouse . up ( ) ;
2022-05-03 17:18:06 +00:00
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . up ( x ) ) ) ;
2022-07-29 23:50:40 +00:00
const afterDownPanBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
2022-03-23 21:10:50 +00:00
expect ( afterDownPanBoundingBox . y ) . toBeLessThan ( afterUpPanBoundingBox . y ) ;
2023-05-18 21:54:46 +00:00
} ) ;
2022-07-15 23:39:55 +00:00
2023-06-20 17:12:45 +00:00
test ( 'Can use alt+shift+drag to create a tag' , async ( { page } ) => {
const canvas = page . locator ( 'canvas' ) ;
await canvas . hover ( { trial : true } ) ;
const canvasBoundingBox = await canvas . boundingBox ( ) ;
const canvasCenterX = canvasBoundingBox . x + canvasBoundingBox . width / 2 ;
const canvasCenterY = canvasBoundingBox . y + canvasBoundingBox . height / 2 ;
await Promise . all ( tagHotkey . map ( ( x ) => page . keyboard . down ( x ) ) ) ;
await page . mouse . down ( ) ;
// steps not working for me here
await page . mouse . move ( canvasCenterX - 20 , canvasCenterY - 20 ) ;
await page . mouse . move ( canvasCenterX - 100 , canvasCenterY - 100 ) ;
await page . mouse . up ( ) ;
await Promise . all ( tagHotkey . map ( ( x ) => page . keyboard . up ( x ) ) ) ;
2023-08-10 16:20:16 +00:00
//Wait for canvas to stabilize.
2023-06-20 17:12:45 +00:00
await canvas . hover ( { trial : true } ) ;
// add some tags
await page . getByText ( 'Annotations' ) . click ( ) ;
await page . getByRole ( 'button' , { name : /Add Tag/ } ) . click ( ) ;
await page . getByPlaceholder ( 'Type to select tag' ) . click ( ) ;
await page . getByText ( 'Driving' ) . click ( ) ;
await page . getByRole ( 'button' , { name : /Add Tag/ } ) . click ( ) ;
await page . getByPlaceholder ( 'Type to select tag' ) . click ( ) ;
await page . getByText ( 'Science' ) . click ( ) ;
} ) ;
2022-06-04 01:24:43 +00:00
test ( 'Can use + - buttons to zoom on the image @unstable' , async ( { page } ) => {
2022-05-18 01:44:16 +00:00
await buttonZoomOnImageAndAssert ( page ) ;
2023-05-18 21:54:46 +00:00
} ) ;
2022-05-18 01:44:16 +00:00
2022-07-15 23:39:55 +00:00
test ( 'Can use the reset button to reset the image @unstable' , async ( { page } , testInfo ) => {
test . slow ( testInfo . project === 'chrome-beta' , 'This test is slow in chrome-beta' ) ;
// Get initial image dimensions
const initialBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
2022-09-19 17:18:20 +00:00
// Zoom in twice via button
await zoomIntoImageryByButton ( page ) ;
await zoomIntoImageryByButton ( page ) ;
2022-03-23 21:10:50 +00:00
2022-09-12 16:19:24 +00:00
// Get and assert zoomed in image dimensions
2023-04-18 22:32:29 +00:00
const zoomedInBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
2022-09-12 16:19:24 +00:00
expect . soft ( zoomedInBoundingBox . height ) . toBeGreaterThan ( initialBoundingBox . height ) ;
2023-04-18 22:32:29 +00:00
expect . soft ( zoomedInBoundingBox . width ) . toBeGreaterThan ( initialBoundingBox . width ) ;
2022-05-20 17:26:54 +00:00
2022-09-12 16:19:24 +00:00
// Reset pan and zoom and assert against initial image dimensions
await resetImageryPanAndZoom ( page ) ;
const finalBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
expect ( finalBoundingBox ) . toEqual ( initialBoundingBox ) ;
2023-05-18 21:54:46 +00:00
} ) ;
2022-09-12 16:19:24 +00:00
test ( 'Using the zoom features does not pause telemetry' , async ( { page } ) => {
const pausePlayButton = page . locator ( '.c-button.pause-play' ) ;
2022-05-20 17:26:54 +00:00
2023-07-19 00:32:05 +00:00
// switch to realtime
await setRealTimeMode ( page ) ;
2022-05-20 17:26:54 +00:00
2022-09-12 16:19:24 +00:00
await expect . soft ( pausePlayButton ) . not . toHaveClass ( /is-paused/ ) ;
2022-05-20 17:26:54 +00:00
// Zoom in via button
2022-09-12 16:19:24 +00:00
await zoomIntoImageryByButton ( page ) ;
2022-11-07 23:50:33 +00:00
await expect ( pausePlayButton ) . not . toHaveClass ( /is-paused/ ) ;
2022-05-20 17:26:54 +00:00
} ) ;
2022-09-12 16:19:24 +00:00
test ( 'Uses low fetch priority' , async ( { page } ) => {
const priority = await page . locator ( '.js-imageryView-image' ) . getAttribute ( 'fetchpriority' ) ;
2023-07-28 02:06:41 +00:00
expect ( priority ) . toBe ( 'low' ) ;
2023-05-18 21:54:46 +00:00
} ) ;
} ) ;
2022-05-20 17:26:54 +00:00
2022-03-23 21:10:50 +00:00
test . describe ( 'Example Imagery in Display Layout' , ( ) => {
2022-09-12 16:19:24 +00:00
let displayLayout ;
test . beforeEach ( async ( { page } ) => {
// Go to baseURL
2023-04-18 22:32:29 +00:00
await page . goto ( './' , { waitUntil : 'domcontentloaded' } ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
displayLayout = await createDomainObjectWithDefaults ( page , { type : 'Display Layout' } ) ;
await page . goto ( displayLayout . url ) ;
2023-05-18 21:54:46 +00:00
2023-06-16 22:14:38 +00:00
await createImageryView ( page ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
await expect ( page . locator ( '.l-browse-bar__object-name' ) ) . toContainText (
'Unnamed Example Imagery'
2023-05-18 21:54:46 +00:00
) ;
2022-09-12 16:19:24 +00:00
await page . goto ( displayLayout . url ) ;
2023-05-18 21:54:46 +00:00
} ) ;
2023-01-20 02:45:40 +00:00
test ( 'View Large action pauses imagery when in realtime and returns to realtime' , async ( {
2023-05-18 21:54:46 +00:00
page
} ) => {
2023-01-20 02:45:40 +00:00
test . info ( ) . annotations . push ( {
type : 'issue' ,
description : 'https://github.com/nasa/openmct/issues/3647'
2022-09-12 16:19:24 +00:00
} ) ;
2022-05-20 17:26:54 +00:00
2023-01-20 02:45:40 +00:00
// set realtime mode
2023-07-19 00:32:05 +00:00
await setRealTimeMode ( page ) ;
2023-01-20 02:45:40 +00:00
// pause/play button
2023-07-28 02:06:41 +00:00
const pausePlayButton = page . locator ( '.c-button.pause-play' ) ;
2023-01-20 02:45:40 +00:00
await expect . soft ( pausePlayButton ) . not . toHaveClass ( /is-paused/ ) ;
// Open context menu and click view large menu item
await page . locator ( 'button[title="View menu items"]' ) . click ( ) ;
await page . locator ( 'li[title="View Large"]' ) . click ( ) ;
await expect ( pausePlayButton ) . toHaveClass ( /is-paused/ ) ;
await page . locator ( '[aria-label="Close"]' ) . click ( ) ;
await expect . soft ( pausePlayButton ) . not . toHaveClass ( /is-paused/ ) ;
2023-05-18 21:54:46 +00:00
} ) ;
2023-01-20 02:45:40 +00:00
test ( 'View Large action leaves keeps realtime mode paused' , async ( { page } ) => {
test . info ( ) . annotations . push ( {
type : 'issue' ,
description : 'https://github.com/nasa/openmct/issues/3647'
} ) ;
// set realtime mode
2023-07-19 00:32:05 +00:00
await setRealTimeMode ( page ) ;
2023-01-20 02:45:40 +00:00
// pause/play button
2023-07-28 02:06:41 +00:00
const pausePlayButton = page . locator ( '.c-button.pause-play' ) ;
2023-01-20 02:45:40 +00:00
await pausePlayButton . click ( ) ;
await expect . soft ( pausePlayButton ) . toHaveClass ( /is-paused/ ) ;
// Open context menu and click view large menu item
await page . locator ( 'button[title="View menu items"]' ) . click ( ) ;
await page . locator ( 'li[title="View Large"]' ) . click ( ) ;
await expect ( pausePlayButton ) . toHaveClass ( /is-paused/ ) ;
await page . locator ( '[aria-label="Close"]' ) . click ( ) ;
await expect . soft ( pausePlayButton ) . toHaveClass ( /is-paused/ ) ;
2023-05-18 21:54:46 +00:00
} ) ;
2023-01-20 02:45:40 +00:00
test ( 'Imagery View operations @unstable' , async ( { page } ) => {
test . info ( ) . annotations . push ( {
2022-09-12 16:19:24 +00:00
type : 'issue' ,
2023-01-20 02:45:40 +00:00
description : 'https://github.com/nasa/openmct/issues/5265'
} ) ;
2022-09-12 16:19:24 +00:00
// Edit mode
await page . click ( 'button[title="Edit"]' ) ;
2022-05-20 17:26:54 +00:00
2022-09-12 16:19:24 +00:00
// Click on example imagery to expose toolbar
await page . locator ( '.c-so-view__header' ) . click ( ) ;
2022-05-20 17:26:54 +00:00
2022-09-12 16:19:24 +00:00
// Adjust object height
await page . locator ( 'div[title="Resize object height"] > input' ) . click ( ) ;
await page . locator ( 'div[title="Resize object height"] > input' ) . fill ( '50' ) ;
2022-05-20 17:26:54 +00:00
2022-09-12 16:19:24 +00:00
// Adjust object width
await page . locator ( 'div[title="Resize object width"] > input' ) . click ( ) ;
await page . locator ( 'div[title="Resize object width"] > input' ) . fill ( '50' ) ;
2022-05-20 17:26:54 +00:00
2022-09-12 16:19:24 +00:00
await performImageryViewOperationsAndAssert ( page ) ;
} ) ;
2022-05-20 17:26:54 +00:00
2022-09-12 16:19:24 +00:00
test ( 'Resizing the layout changes thumbnail visibility and size' , async ( { page } ) => {
const thumbsWrapperLocator = page . locator ( '.c-imagery__thumbs-wrapper' ) ;
2022-05-20 17:26:54 +00:00
// Edit mode
2022-09-12 16:19:24 +00:00
await page . click ( 'button[title="Edit"]' ) ;
2022-05-20 17:26:54 +00:00
// Click on example imagery to expose toolbar
2022-09-12 16:19:24 +00:00
await page . locator ( '.c-so-view__header' ) . click ( ) ;
2022-05-20 17:26:54 +00:00
// expect thumbnails not be visible when first added
2022-05-26 16:45:16 +00:00
expect . soft ( thumbsWrapperLocator . isHidden ( ) ) . toBeTruthy ( ) ;
2022-05-20 17:26:54 +00:00
// Resize the example imagery vertically to change the thumbnail visibility
/ *
The following arbitrary values are added to observe the separate visual
conditions of the thumbnails ( hidden , small thumbnails , regular thumbnails ) .
Specifically , height is set to 50 px for small thumbs and 100 px for regular
* /
2022-09-12 16:19:24 +00:00
await page . locator ( 'div[title="Resize object height"] > input' ) . click ( ) ;
await page . locator ( 'div[title="Resize object height"] > input' ) . fill ( '50' ) ;
2022-05-20 17:26:54 +00:00
expect ( thumbsWrapperLocator . isVisible ( ) ) . toBeTruthy ( ) ;
await expect ( thumbsWrapperLocator ) . toHaveClass ( /is-small-thumbs/ ) ;
// Resize the example imagery vertically to change the thumbnail visibility
2022-09-12 16:19:24 +00:00
await page . locator ( 'div[title="Resize object height"] > input' ) . click ( ) ;
await page . locator ( 'div[title="Resize object height"] > input' ) . fill ( '100' ) ;
2022-05-20 17:26:54 +00:00
2023-06-16 22:14:38 +00:00
await expect ( thumbsWrapperLocator ) . toBeVisible ( ) ;
2022-05-20 17:26:54 +00:00
await expect ( thumbsWrapperLocator ) . not . toHaveClass ( /is-small-thumbs/ ) ;
} ) ;
2023-06-16 22:14:38 +00:00
/ * *
* Toggle layer visibility checkbox by clicking on checkbox label
* - should toggle checkbox and layer visibility for that image view
2023-08-10 16:20:16 +00:00
* - should NOT toggle checkbox and layer visibility for the first image view in display
2023-06-16 22:14:38 +00:00
* /
test ( 'Toggle layer visibility by clicking on label' , async ( { page } ) => {
test . info ( ) . annotations . push ( {
type : 'issue' ,
description : 'https://github.com/nasa/openmct/issues/6709'
} ) ;
await createImageryView ( page ) ;
await page . goto ( displayLayout . url ) ;
const imageElements = page . locator ( '.c-imagery__main-image-wrapper' ) ;
await expect ( imageElements ) . toHaveCount ( 2 ) ;
const imageOne = page . locator ( '.c-imagery__main-image-wrapper' ) . nth ( 0 ) ;
const imageTwo = page . locator ( '.c-imagery__main-image-wrapper' ) . nth ( 1 ) ;
const imageOneWrapper = imageOne . locator ( '.image-wrapper' ) ;
const imageTwoWrapper = imageTwo . locator ( '.image-wrapper' ) ;
await imageTwo . hover ( ) ;
await imageTwo . locator ( 'button[title="Layers"]' ) . click ( ) ;
const imageTwoLayersMenuContent = imageTwo . locator ( 'button[title="Layers"] + div' ) ;
const imageTwoLayersToggleLabel = imageTwoLayersMenuContent . locator ( 'label' ) . last ( ) ;
await imageTwoLayersToggleLabel . click ( ) ;
const imageOneLayers = imageOneWrapper . locator ( '.layer-image' ) ;
const imageTwoLayers = imageTwoWrapper . locator ( '.layer-image' ) ;
await expect ( imageOneLayers ) . toHaveCount ( 0 ) ;
await expect ( imageTwoLayers ) . toHaveCount ( 1 ) ;
} ) ;
2022-05-20 17:26:54 +00:00
} ) ;
2022-03-23 21:10:50 +00:00
test . describe ( 'Example Imagery in Flexible layout' , ( ) => {
2022-09-12 16:19:24 +00:00
let flexibleLayout ;
test . beforeEach ( async ( { page } ) => {
2023-04-18 22:32:29 +00:00
await page . goto ( './' , { waitUntil : 'domcontentloaded' } ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
flexibleLayout = await createDomainObjectWithDefaults ( page , { type : 'Flexible Layout' } ) ;
await page . goto ( flexibleLayout . url ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
/* Create Sine Wave Generator with minimum Image Load Delay */
2022-06-11 13:45:09 +00:00
// Click the Create button
await page . click ( 'button:has-text("Create")' ) ;
2023-05-18 21:54:46 +00:00
2022-06-11 13:45:09 +00:00
// Click text=Example Imagery
2022-11-07 23:50:33 +00:00
await page . click ( 'li[role="menuitem"]:has-text("Example Imagery")' ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
// Clear and set Image load delay to minimum value
await page . locator ( 'input[type="number"]' ) . fill ( '' ) ;
await page . locator ( 'input[type="number"]' ) . fill ( '5000' ) ;
2023-05-18 21:54:46 +00:00
2022-06-11 13:45:09 +00:00
// Click text=OK
await Promise . all ( [
page . waitForNavigation ( { waitUntil : 'networkidle' } ) ,
2022-11-07 23:50:33 +00:00
page . click ( 'button:has-text("OK")' ) ,
2022-06-11 13:45:09 +00:00
//Wait for Save Banner to appear
page . waitForSelector ( '.c-message-banner__message' )
] ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
await expect ( page . locator ( '.l-browse-bar__object-name' ) ) . toContainText (
'Unnamed Example Imagery'
) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
await page . goto ( flexibleLayout . url ) ;
2023-05-18 21:54:46 +00:00
} ) ;
2022-09-12 16:19:24 +00:00
test ( 'Imagery View operations @unstable' , async ( { page , browserName } ) => {
test . fixme ( browserName === 'firefox' , 'This test needs to be updated to work with firefox' ) ;
test . info ( ) . annotations . push ( {
type : 'issue' ,
description : 'https://github.com/nasa/openmct/issues/5326'
} ) ;
2022-06-11 13:45:09 +00:00
2022-09-12 16:19:24 +00:00
await performImageryViewOperationsAndAssert ( page ) ;
} ) ;
} ) ;
2022-06-11 13:45:09 +00:00
2022-09-12 16:19:24 +00:00
test . describe ( 'Example Imagery in Tabs View' , ( ) => {
let tabsView ;
test . beforeEach ( async ( { page } ) => {
2023-04-18 22:32:29 +00:00
await page . goto ( './' , { waitUntil : 'domcontentloaded' } ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
tabsView = await createDomainObjectWithDefaults ( page , { type : 'Tabs View' } ) ;
await page . goto ( tabsView . url ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
/* Create Sine Wave Generator with minimum Image Load Delay */
// Click the Create button
await page . click ( 'button:has-text("Create")' ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
// Click text=Example Imagery
2022-11-07 23:50:33 +00:00
await page . click ( 'li[role="menuitem"]:has-text("Example Imagery")' ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
// Clear and set Image load delay to minimum value
await page . locator ( 'input[type="number"]' ) . fill ( '' ) ;
await page . locator ( 'input[type="number"]' ) . fill ( '5000' ) ;
2023-05-18 21:54:46 +00:00
2022-06-11 13:45:09 +00:00
// Click text=OK
2022-09-12 16:19:24 +00:00
await Promise . all ( [
page . waitForNavigation ( { waitUntil : 'networkidle' } ) ,
2022-11-07 23:50:33 +00:00
page . click ( 'button:has-text("OK")' ) ,
2022-09-12 16:19:24 +00:00
//Wait for Save Banner to appear
page . waitForSelector ( '.c-message-banner__message' )
] ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
await expect ( page . locator ( '.l-browse-bar__object-name' ) ) . toContainText (
'Unnamed Example Imagery'
) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
await page . goto ( tabsView . url ) ;
} ) ;
test ( 'Imagery View operations @unstable' , async ( { page } ) => {
await performImageryViewOperationsAndAssert ( page ) ;
2022-06-11 13:45:09 +00:00
} ) ;
2.0.5 Backmerge (#5505)
* Bump d3-selection from 1.3.2 to 3.0.0
Bumps [d3-selection](https://github.com/d3/d3-selection) from 1.3.2 to 3.0.0.
- [Release notes](https://github.com/d3/d3-selection/releases)
- [Commits](https://github.com/d3/d3-selection/compare/v1.3.2...v3.0.0)
---
updated-dependencies:
- dependency-name: d3-selection
dependency-type: direct:development
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
* Remove snapshot
* Fix imagery filter slider drag in flexible layouts (#5326) (#5350)
* Dont' mutate a stacked plot unless its user initiated (#5357)
* Port grid icons and imagery test to release 2.0.5 from master (#5360)
* Port grid icons to release 2.0.5 from master
* Port imagery test to release/2.0.5
* Restrict timestrip composition to time based plots, plans and imagery (#5161)
* Restrict timestrip composition to time based plots, plans and imagery
* Adds unit tests for timeline composition policy
* Addresses review comments
Improves tests
* Reuse test objects
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
* Include objectStyles reference to conditionSetIdentifier in imports (#5354)
* Include objectStyles reference to conditionSetIdentifier in imports
* Add tests for export
* Refactored some code and removed console log
* Remove workarounds for chrome 'scrollTop' issue (#5375)
* Fix naming of method (#5368)
* Imagery View does not discard old images when they fall out of bounds (#5351)
* change to using telemetry collection
* fix tests
* added more unit tests
* Cherrypicked commits (#5390)
Co-authored-by: unlikelyzero <jchill2@gmail.com>
* [Timer] Update 3dot menu actions appropriately (#5387)
* Call `removeAllListeners()` after emit
* Manually show/hide actions if within a view
* remove sneaky `console.log()`
* Add Timer e2e test
* Add to comments
* Avoid hard waits in Timer e2e test
- Assert against timer view state instead of menu options
* Let's also test actions from the Timer view
* 5391 Add preview and drag support to Grand Search (#5394)
* add preview and drag actions
* added unit test, simplified remove action
* do not hide search results in preview mode when clicking outside search results
* add semantic aria labels to enable e2e tests
* readd preview
* add e2e test
* remove commented out url
* add percy snapshot and add search to ci
* make percy stuff work
* linting
* fix percy again
* move percy snapshots to a visual test
* added separate visual test and changed test to fixtures
* fix fixtures path
* addressing review comments
* 5361 tags not persisting locally (#5408)
* fixed typo
* remove unneeded lookup
* fix tags adding and deleting
* more reliable way to remove tags
* break tests up for parallel execution
* fixed notebook tagging test
* enable e2e tests
* made schedule index comment more clear and fix uppercase/lowercase issue
* address e2e changes
* add unit test to bump coverage
* fix typo
* need to check on annotation creation if provider exists or not
* added fixtures
* undo silly couchdb commit
* Plot progress bar fix for 2.0.5 (#5386)
* Add .bind(this) to stopLoading() in loadMoreData()
* Replace load spinner with progress bar for plots
* Add loading delay prop to swg
* fix linting errors
* match load order
* Update accessibility
* Add Math.max to timeout to handle negative inputs
* Moved math.max to load delay variable
* Add loading fix for stacked plots
* Move loadingUpdate func into plot item for update
* Merge conflict resolve
* Check if delay is 0 and send, put post in a func
* Put obj directly to model, removed computed prop
* Lint fix
* Fix template where legend was not displayed
* Remove commented out template
* Fixed failing test
Co-authored-by: unlikelyzero <jchill2@gmail.com>
* Make plans non editable. (#5377)
* Make plans non editable.
* Add unit test for fix
* [CouchDB] Better determination of indicator status (#5415)
* Add unknown state, remove maintenance state
* Handle all CouchDB status codes
- Set unknown status if we receive an unhandled code
* Include status code in error messages
* SharedWorker can send unknown status
* Add test for unknown status
* Gauge fixes for Firefox and units display (#5369)
* Closes #5323, #5325. Parent branch is release/2.0.5.
- Significant work refactoring SVG markup and CSS for dial gauge;
- Fixed missing `v-if` to control display of units for #5325;
- Fixed bad `.length` test for limit properties;
* Closes #5323, #5325
- Add 'value out of range' indicator
* Closes #5323, #5325
- More accurate element naming;
- Fix cross-browser problems with current value display in dial gauge;
- Refinements to "out of range" indicator approach;
- Fixed size of "Amplitude" input in Sine Wave Generator;
* Closes #5323, #5325
- Styles and stubbed in code to support needle meter type;
* Closes #5323, #5325
- Stubbed in markup and CSS for needle-style meter;
* Closes #5323, #5325
- Fixed missing `js-*` classes that were failing npm run test;
* Closes #5323, #5325
- Fix to not display meter value bar unless a data value is expected;
* Addressing PR comments
- Renamed method for clarity;
- Added null value check in method `valueExpected`;
* [Static Root] Return leafValue if null/undefined/false (#5416)
* Return leafValue if null/undefined/false
* Added a null to the test json
* Show a better default poll question (#5425)
* 5361 Tags not persisting when several notebook entries are created at once (#5428)
* add end to end test to catch multiple entry errors
* click expansion triangle instead
* fix race condition between annotation creation and mutation
* make sure notebook tags run in e2e
* address PR comments
* Handle missing objects gracefully (#5399)
* Handle missing object errors for display layouts
* Handle missing object errors for Overlay Plots
* Add check for this.config
* Add try/catch statement & check if obj is missing
* Changed console.error to console.warn
* Lint fix
* Fix for this.metadata.value is undefined
* Add e2e test
* Update comment text
* Add reload check and @private, verify console.warn
* Redid assignment and metadata check
* Fix typo
* Changed assignment and metadata check
* Redid checks for isMissing(object)
* Lint fix
* Backmerge e2e code coverage changes and fixes into release/2.0.5 (#5431)
* [Telemetry Collections] Respect "Latest" Strategy Option (#5421)
* Respect latest strategy in Telemetry Collections to limit potential memory growth.
* fix sourcemaps (#5373)
Co-authored-by: John Hill <john.c.hill@nasa.gov>
* Debounce status summary (#5448)
Co-authored-by: John Hill <john.c.hill@nasa.gov>
* No gauge (#5451)
* Installed gauge plugin by default
* Make gauge part of standard install in e2e suite and add restrictednotebook
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* [CouchDB] Always subscribe to the CouchDB changes feed (#5434)
* Add unknown state, remove maintenance state
* Handle all CouchDB status codes
- Set unknown status if we receive an unhandled code
* Include status code in error messages
* SharedWorker can send unknown status
* Add test for unknown status
* Always subscribe to CouchDB changes feed
- Always subscribe to the CouchDB changes feed, even if there are no observable objects, since we are also checking the status of CouchDB via this feed.
* Update indicator status if not using SharedWorker
* Start listening to changes feed on first request
* fix test
* adjust test to hopefully avoid race condition
* lint
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
* Fix for Fault Management Visual Bugs (#5376)
* Closes #5365
* General visual improvements
Co-authored-by: Charles Hacskaylo <charlesh88@gmail.com>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* fix pathing (#5452)
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* [Static Root] Static Root Plugin not loading (#5455)
* Log if hitting falsy leafValue
* Add some logging
* Remove logs and specify null/undefined
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* Allow endpoints with a single enum metadata value in Bar/Line graphs (#5443)
* If there is only 1 metadata value, set yKey to none. Also, fix bug for determining the name of a metadata value
* Update tests for enum metadata values
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* [Remote Clock] Wait for first tick and recalculate historical request bounds (#5433)
* Updated to ES6 class
* added request intercept functionality to telemetry api, added a request interceptor for remote clock
* add remoteClock e2e test stub
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Fix for missing object for LADTableSet (#5458)
* Handle missing object errors for display layouts
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* removing the call for default import now that TelemetryAPI is an ES6 class (#5461)
* [Remote Clock] Fix requestInterceptor typo (#5462)
* Fix typo in telemetry request interceptor
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Lock model (#5457)
* Lock event Model to prevent reactification
* de-reactify all the things
* Make API properties writable to allow test mocks to override them
* Fix merge conflict
* Added plot interceptor for missing series config (#5422)
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Shefali Joshi <simplyrender@gmail.com>
* Remove performance marks (#5465)
* Remove performance marks
* Retain performance mark in view large. It doesn't happen very often and it's needed for an automated performance test
* Use timeKey for time comparison (#5471)
* Fix couchdb no response (#5474)
* Update the creation date only when the document is created for the first time
* If there is no response from a bulk get, couch db has issues
* Check the response - if it's null, don't apply interceptors
* Fix shelved alarms (#5479)
* Fix the logic around shelved alarms
* Remove application router listener
* Release 2.0.5 UI and Gauge fixes (#5470)
* Various UI fixes
- Tweak to Gauge properties form for clarity and usability.
- Fix Gauge 'dial' type not obeying "Show units" property setting, closes #5325.
- Tweaks to Operator Status UI label and layout for clarity.
- Changed name and description of Graph object for clarity and consistency.
- Fixed CSS classing that was coloring Export menu items text incorrectly.
- Fixed icon-to-text vertical alignment in `.c-object-label`.
- Fix for broken layout in imagery local controls (brightness, layers, magnification).
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Stacked plot interceptor rename (#5468)
* Rename stacked plot interceptor and move to folder
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Clear data when time bounds are changed (#5482)
* Clear data when time bounds are changed
Also react to clear data action
Ensure that the yKey is set to 'none' if there is no range with array Values
* Refactor trace updates to a method
* get rid of root (#5483)
* Do not pass onPartialResponse option on to upstream telemetry (#5486)
* Fix all of the e2e tests (#5477)
* Fix timer test
* be explicit about the warnings text
* add full suite to CI to enable CircleCI Checks
* add back in devtool=false for CI env so firefox tests run
* add framework suite
* Don't install webpack HMR in CI
* Fix playwright version installs
* exclude HMR if running tests in any environment
- use NODE_ENV=TEST to exclude webpack HMR
- deparameterize some of the playwright configs
* use lower-case 'test'
* timer hover fix
* conditionally skip for firefox due to missing console events
* increase timeouts to give time for mutation
* no need to close save banner
* remove devtool setting
* revert
* update snapshots
* disable video to save some resources
* use one worker
* more timeouts :)
* Remove `browser.close()` and `page.close()` as it was breaking other tests
* Remove unnecessary awaits and fix func call syntax
* Fix image reset test
* fix restrictedNotebook tests
* revert playwright-ci.config settings
* increase timeout for polling imagery test
* remove unnecessary waits
* disable notebook lock test for chrome-beta as its unreliable
- remove some unnecessary 'wait for save banner' logic
- remove unused await
- mark imagery test as slow in chrome-beta
* LINT!! *shakes fist*
* don't run full e2e suite per commit
* disable video in all configs
* add flakey zoom comment
* exclude webpack HMR in non-development modes
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* lint fix
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Joshi <simplyrender@gmail.com>
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: unlikelyzero <jchill2@gmail.com>
Co-authored-by: Alize Nguyen <alizenguyen@gmail.com>
Co-authored-by: Charles Hacskaylo <charlesh88@gmail.com>
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
Co-authored-by: rukmini-bose <48999852+rukmini-bose@users.noreply.github.com>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
2022-07-14 21:52:28 +00:00
} ) ;
Merge `release/2.0.8` into `master` (#5709)
* Imagery thumbnail regression fixes - 5327 (#5591)
* Add an active class to thumbnail to indicate current focused image
* Differentiate bg color between real-time and fixed
* scrollIntoView inline: center
* Added watcher for bounds change to trigger thumbnail scroll
* Resolve merge conflict with requestHistory change to telemetry collection
* Split thumbnail into sub component
* Monitor isFixed value to unpause playback status
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
* [e2e] Improve appActions (#5592)
* update selectors to use aria labels
* Update appActions
- Create new function `getHashUrlToDomainObject` to get the browse url to a given object given its uuid
- Create new function `getFocusedObjectUuid`... self explanatory :)
- Update `createDomainObjectWIthDefaults` to make use of the new url generation
- Update `createDomainObject...`'s arguments to be more organized, and accept a parent object
- Update some docs, still need to clarify some
* Update appActions e2e tests
- Refactor for organization
- Test our new appActions in one go
* Update existing usages of `createDomainObject...` to match the new API
* fix accidental renamed export
* Fix jsdoc return types
* refactor telemetryTable test to use appActions
* Improve selectors
* Refactor test
* improve selector
* add clock mode appActions
* lint
* Fix jsdoc
* Code review comments
* mark failing visual tests as fixme temporarily
* Update package.json (#5601)
* Fix menu style in Snow theme (#5557)
* Include the plan source map when generating the time list/plan hybrid object (#5604)
* Search should indicate in progress and no results states, filter orphaned results (#5599)
* no matching result implemented
* now filtering annotations that are orphaned
* filter object results without valid paths
* add progress bar
* added e2e tests
* removed extraneous click
* fix typos
* fix unit tests
* lint
* address pr comments
* fix tests
* fix tests, centralize logic to object api, check for root instead
* remove debug statement
* lint
* fix documentation
* lint
* fix doc
* made some optimizations after talking with akhenry
* fix test
* update docs
* fix docs
* Have in-memory search indexer use composition API (#5578)
* need to remove tags and objects on composition removal
* had to separate out emits from load as it was causing memory indexer to loop upon itself
* Add parsing for areIdsEqual util to consistently remove folders (#5589)
* Add parsing util to identifier for ID comparison
* Moved firstIdentifier to top of function
* Lint fix
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Revert "Have in-memory search indexer use composition API (#5578)" (#5609)
This reverts commit 7cf11e177c6c48093a6b37902ba3dfb36414ff10.
* [e2e] Tests for Display Layout and LAD Tables and telemetry (#5607)
* Check for circular references in originalPath - 5615 (#5619)
* check for circular references
* add test
* fix test
* address PR comments by making comments better
* fix docs...again
* Update version number
* Prevent cyclic references in link & move actions (#5635)
* do not create circular refs
* add negative validation test
* move to plugin
* add link test too
* fix docs
* refactored per john request
* fix path
* use appAction lib
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* [Condition Set] Add check for empty string being passed to the makeKeyString util by TelemetryCriterion (#5636) (#5663)
* Check telemetry is defined before using makeKeyString util
* Add optional chaining in the check
* Add e2e test
* Add check for undefined
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
* [Fault Management] New Example Provider, Unit and e2e tests (#5579)
* added unit tests for fault management plugin
* modified the example fault provider to work out of the box
* updating for new e2e folder structure
* part of the e2e tests
* WIP
* Imagery thumbnail regression fixes - 5327 (#5569)
* Add an active class to thumbnail to indicate current focused image
* Differentiate bg color between real-time and fixed
* scrollIntoView inline: center
* Added watcher for bounds change to trigger thumbnail scroll
* Resolve merge conflict with requestHistory change to telemetry collection
* Split thumbnail into sub component
* Monitor isFixed value to unpause playback status
* updated search to include name, namespace and description added some more e2e tests
* added rest of e2e tests
* fixed my init script, had to disable lint for no-force because it was not working without it, saw online this may be a pw bug
* fix: removing maelstrom theme from application (#5600)
* added some tests for no faults
* visual tests
* added visual tests for fault management
* created utils file for shared functionality between function and visual tests
* updating to 2.0.8
* tryin to remove imagery changes from master
* trying to trigger a refresh
* tryin to refresh
* updated search to include name, namespace and description added some more e2e tests
* added rest of e2e tests
* fix: removing maelstrom theme from application (#5600)
* fixed my init script, had to disable lint for no-force because it was not working without it, saw online this may be a pw bug
* added some tests for no faults
* visual tests
* added visual tests for fault management
* created utils file for shared functionality between function and visual tests
* updating to 2.0.8
* no clue
* still no clue
* removing imports and chaning to requires
* updating utils file to work with require
* fixing paths
* fixing a test I had messed up when adding static exmaple faults
* ONE LAST PATH FIX... hopefully
* typo in files fix
* fix folder typo
* thought I got this one, but apparently not, well I did now! who is laughing now!?
Co-authored-by: Michael Rogers <contact@mhrogers.com>
Co-authored-by: Vitor Henckel <vitor@henckel.com.br>
* Sort tree items locally on rename (#5643)
* fix typo
* Sort the tree items locally on object rename
* Use the navigationPath as a key
- This ensures that objects AND linked objects will be sorted
* add 'tree' and 'treeitem' roles to mct-tree
* WIP tree item reordering test
* Select the first object that matches
* Test that all object links are also reordered
* Get the final uuid before queryParams as notebook sections have uuids
* Make `openObjectTreeContextMenu` more deterministic and update usage
* Add `expandPathToTreeItem` and `expandTreeItemByName` appActions
* add `#tree-pane` id for the tree view
* Add tree visual component test suite and bump percy-cli
* Remove tree appActions
* Better variable name
Co-authored-by: Scott Bell <scott@traclabs.com>
* Mct5549 fix indexer composition error (#5610)
* [Display Layout] Composition and configuration sync (#5669)
LGTM
* [e2e] Stabilize notebook tag tests (#5681)
* Use more deterministic selector
* Hover first to "slow down" e2e actions while in headless mode
* Moves condition set fix into 2.0.8 (#5673)
* Set Focused Image index after a imagery is selected from a timestrip - 5632 (#5664)
* Set focused image when timestamp prop is passed in
* Unused var
* Create timestrip with imagery child
* Add equality check for hovered image and view large image url
* Cleanup
* Time List 5534 for release/2.0.8 (#5678)
* Changes to Time List view. Closes #5534.
- Compacted table row spacing.
- Set all timeframes to display by default when creating a new Time List.
- Removed 'Upload plan' file button from properties.
* Changes to Time List view. Closes #5534.
- Better hint text for editing Timeframe Inspector section.
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* [CI] Enable couchdb e2e testing in open source (#5655)
* Handle couch db not found errors so that interceptors are still invoked. (#5654)
* Fix tests for interceptors
* [e2e] Add test for 'mine' folder initialization
* [e2e] don't fail on expected console errors
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
* [Docs] Update CouchDB local install documentation (#5692)
* Update local CouchDB install docs to include docker workflow
* reformat to source configuration scripts where possible
* correct couchdb case
Co-authored-by: John Hill <john.c.hill@nasa.gov>
* [Time Conductor] History not working correctly (#5687)
* the check for fixed time vs realtime was not updating, have fixed this
* merging in related changes from master pr #4414
* lint fixes
* Update src/plugins/timeConductor/ConductorHistory.vue
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* setting time mode directly on load
* fixing issue where realtime history was being wiped on reloads while viewing fixed time
* formatting
* stubbed in some tests
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* Only index if provider does not support search - mct5690 (#5693)
* only index if provider does not support search
* add some tests
* fix tests
* [e2e] Add search couchdb test for duplicates
* [e2e] Modify existing search test instead
* lint
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
* Don't re-request historical data on ticks (#5701)
Don't rerequest telemetry on ticks.
* Fix duplicate declaration from merge
Co-authored-by: Michael Rogers <contact@mhrogers.com>
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Charles Hacskaylo <charlesh88@gmail.com>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: Alize Nguyen <alizenguyen@gmail.com>
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Vitor Henckel <vitor@henckel.com.br>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
2022-08-24 18:08:17 +00:00
test . describe ( 'Example Imagery in Time Strip' , ( ) => {
2022-09-12 16:19:24 +00:00
let timeStripObject ;
test . beforeEach ( async ( { page } ) => {
2023-04-18 22:32:29 +00:00
await page . goto ( './' , { waitUntil : 'domcontentloaded' } ) ;
2022-09-12 16:19:24 +00:00
timeStripObject = await createDomainObjectWithDefaults ( page , {
2023-01-21 19:25:35 +00:00
type : 'Time Strip'
Merge `release/2.0.8` into `master` (#5709)
* Imagery thumbnail regression fixes - 5327 (#5591)
* Add an active class to thumbnail to indicate current focused image
* Differentiate bg color between real-time and fixed
* scrollIntoView inline: center
* Added watcher for bounds change to trigger thumbnail scroll
* Resolve merge conflict with requestHistory change to telemetry collection
* Split thumbnail into sub component
* Monitor isFixed value to unpause playback status
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
* [e2e] Improve appActions (#5592)
* update selectors to use aria labels
* Update appActions
- Create new function `getHashUrlToDomainObject` to get the browse url to a given object given its uuid
- Create new function `getFocusedObjectUuid`... self explanatory :)
- Update `createDomainObjectWIthDefaults` to make use of the new url generation
- Update `createDomainObject...`'s arguments to be more organized, and accept a parent object
- Update some docs, still need to clarify some
* Update appActions e2e tests
- Refactor for organization
- Test our new appActions in one go
* Update existing usages of `createDomainObject...` to match the new API
* fix accidental renamed export
* Fix jsdoc return types
* refactor telemetryTable test to use appActions
* Improve selectors
* Refactor test
* improve selector
* add clock mode appActions
* lint
* Fix jsdoc
* Code review comments
* mark failing visual tests as fixme temporarily
* Update package.json (#5601)
* Fix menu style in Snow theme (#5557)
* Include the plan source map when generating the time list/plan hybrid object (#5604)
* Search should indicate in progress and no results states, filter orphaned results (#5599)
* no matching result implemented
* now filtering annotations that are orphaned
* filter object results without valid paths
* add progress bar
* added e2e tests
* removed extraneous click
* fix typos
* fix unit tests
* lint
* address pr comments
* fix tests
* fix tests, centralize logic to object api, check for root instead
* remove debug statement
* lint
* fix documentation
* lint
* fix doc
* made some optimizations after talking with akhenry
* fix test
* update docs
* fix docs
* Have in-memory search indexer use composition API (#5578)
* need to remove tags and objects on composition removal
* had to separate out emits from load as it was causing memory indexer to loop upon itself
* Add parsing for areIdsEqual util to consistently remove folders (#5589)
* Add parsing util to identifier for ID comparison
* Moved firstIdentifier to top of function
* Lint fix
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Revert "Have in-memory search indexer use composition API (#5578)" (#5609)
This reverts commit 7cf11e177c6c48093a6b37902ba3dfb36414ff10.
* [e2e] Tests for Display Layout and LAD Tables and telemetry (#5607)
* Check for circular references in originalPath - 5615 (#5619)
* check for circular references
* add test
* fix test
* address PR comments by making comments better
* fix docs...again
* Update version number
* Prevent cyclic references in link & move actions (#5635)
* do not create circular refs
* add negative validation test
* move to plugin
* add link test too
* fix docs
* refactored per john request
* fix path
* use appAction lib
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* [Condition Set] Add check for empty string being passed to the makeKeyString util by TelemetryCriterion (#5636) (#5663)
* Check telemetry is defined before using makeKeyString util
* Add optional chaining in the check
* Add e2e test
* Add check for undefined
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
* [Fault Management] New Example Provider, Unit and e2e tests (#5579)
* added unit tests for fault management plugin
* modified the example fault provider to work out of the box
* updating for new e2e folder structure
* part of the e2e tests
* WIP
* Imagery thumbnail regression fixes - 5327 (#5569)
* Add an active class to thumbnail to indicate current focused image
* Differentiate bg color between real-time and fixed
* scrollIntoView inline: center
* Added watcher for bounds change to trigger thumbnail scroll
* Resolve merge conflict with requestHistory change to telemetry collection
* Split thumbnail into sub component
* Monitor isFixed value to unpause playback status
* updated search to include name, namespace and description added some more e2e tests
* added rest of e2e tests
* fixed my init script, had to disable lint for no-force because it was not working without it, saw online this may be a pw bug
* fix: removing maelstrom theme from application (#5600)
* added some tests for no faults
* visual tests
* added visual tests for fault management
* created utils file for shared functionality between function and visual tests
* updating to 2.0.8
* tryin to remove imagery changes from master
* trying to trigger a refresh
* tryin to refresh
* updated search to include name, namespace and description added some more e2e tests
* added rest of e2e tests
* fix: removing maelstrom theme from application (#5600)
* fixed my init script, had to disable lint for no-force because it was not working without it, saw online this may be a pw bug
* added some tests for no faults
* visual tests
* added visual tests for fault management
* created utils file for shared functionality between function and visual tests
* updating to 2.0.8
* no clue
* still no clue
* removing imports and chaning to requires
* updating utils file to work with require
* fixing paths
* fixing a test I had messed up when adding static exmaple faults
* ONE LAST PATH FIX... hopefully
* typo in files fix
* fix folder typo
* thought I got this one, but apparently not, well I did now! who is laughing now!?
Co-authored-by: Michael Rogers <contact@mhrogers.com>
Co-authored-by: Vitor Henckel <vitor@henckel.com.br>
* Sort tree items locally on rename (#5643)
* fix typo
* Sort the tree items locally on object rename
* Use the navigationPath as a key
- This ensures that objects AND linked objects will be sorted
* add 'tree' and 'treeitem' roles to mct-tree
* WIP tree item reordering test
* Select the first object that matches
* Test that all object links are also reordered
* Get the final uuid before queryParams as notebook sections have uuids
* Make `openObjectTreeContextMenu` more deterministic and update usage
* Add `expandPathToTreeItem` and `expandTreeItemByName` appActions
* add `#tree-pane` id for the tree view
* Add tree visual component test suite and bump percy-cli
* Remove tree appActions
* Better variable name
Co-authored-by: Scott Bell <scott@traclabs.com>
* Mct5549 fix indexer composition error (#5610)
* [Display Layout] Composition and configuration sync (#5669)
LGTM
* [e2e] Stabilize notebook tag tests (#5681)
* Use more deterministic selector
* Hover first to "slow down" e2e actions while in headless mode
* Moves condition set fix into 2.0.8 (#5673)
* Set Focused Image index after a imagery is selected from a timestrip - 5632 (#5664)
* Set focused image when timestamp prop is passed in
* Unused var
* Create timestrip with imagery child
* Add equality check for hovered image and view large image url
* Cleanup
* Time List 5534 for release/2.0.8 (#5678)
* Changes to Time List view. Closes #5534.
- Compacted table row spacing.
- Set all timeframes to display by default when creating a new Time List.
- Removed 'Upload plan' file button from properties.
* Changes to Time List view. Closes #5534.
- Better hint text for editing Timeframe Inspector section.
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* [CI] Enable couchdb e2e testing in open source (#5655)
* Handle couch db not found errors so that interceptors are still invoked. (#5654)
* Fix tests for interceptors
* [e2e] Add test for 'mine' folder initialization
* [e2e] don't fail on expected console errors
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
* [Docs] Update CouchDB local install documentation (#5692)
* Update local CouchDB install docs to include docker workflow
* reformat to source configuration scripts where possible
* correct couchdb case
Co-authored-by: John Hill <john.c.hill@nasa.gov>
* [Time Conductor] History not working correctly (#5687)
* the check for fixed time vs realtime was not updating, have fixed this
* merging in related changes from master pr #4414
* lint fixes
* Update src/plugins/timeConductor/ConductorHistory.vue
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* setting time mode directly on load
* fixing issue where realtime history was being wiped on reloads while viewing fixed time
* formatting
* stubbed in some tests
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* Only index if provider does not support search - mct5690 (#5693)
* only index if provider does not support search
* add some tests
* fix tests
* [e2e] Add search couchdb test for duplicates
* [e2e] Modify existing search test instead
* lint
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
* Don't re-request historical data on ticks (#5701)
Don't rerequest telemetry on ticks.
* Fix duplicate declaration from merge
Co-authored-by: Michael Rogers <contact@mhrogers.com>
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Charles Hacskaylo <charlesh88@gmail.com>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: Alize Nguyen <alizenguyen@gmail.com>
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Vitor Henckel <vitor@henckel.com.br>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
2022-08-24 18:08:17 +00:00
} ) ;
await createDomainObjectWithDefaults ( page , {
type : 'Example Imagery' ,
parent : timeStripObject . uuid
} ) ;
// Navigate to timestrip
await page . goto ( timeStripObject . url ) ;
2023-05-18 21:54:46 +00:00
} ) ;
2022-09-12 16:19:24 +00:00
test ( 'Clicking a thumbnail loads the image in large view' , async ( { page , browserName } ) => {
test . info ( ) . annotations . push ( {
type : 'issue' ,
description : 'https://github.com/nasa/openmct/issues/5632'
} ) ;
2023-01-21 19:25:35 +00:00
// Hover over the timestrip to reveal a thumbnail image
Merge `release/2.0.8` into `master` (#5709)
* Imagery thumbnail regression fixes - 5327 (#5591)
* Add an active class to thumbnail to indicate current focused image
* Differentiate bg color between real-time and fixed
* scrollIntoView inline: center
* Added watcher for bounds change to trigger thumbnail scroll
* Resolve merge conflict with requestHistory change to telemetry collection
* Split thumbnail into sub component
* Monitor isFixed value to unpause playback status
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
* [e2e] Improve appActions (#5592)
* update selectors to use aria labels
* Update appActions
- Create new function `getHashUrlToDomainObject` to get the browse url to a given object given its uuid
- Create new function `getFocusedObjectUuid`... self explanatory :)
- Update `createDomainObjectWIthDefaults` to make use of the new url generation
- Update `createDomainObject...`'s arguments to be more organized, and accept a parent object
- Update some docs, still need to clarify some
* Update appActions e2e tests
- Refactor for organization
- Test our new appActions in one go
* Update existing usages of `createDomainObject...` to match the new API
* fix accidental renamed export
* Fix jsdoc return types
* refactor telemetryTable test to use appActions
* Improve selectors
* Refactor test
* improve selector
* add clock mode appActions
* lint
* Fix jsdoc
* Code review comments
* mark failing visual tests as fixme temporarily
* Update package.json (#5601)
* Fix menu style in Snow theme (#5557)
* Include the plan source map when generating the time list/plan hybrid object (#5604)
* Search should indicate in progress and no results states, filter orphaned results (#5599)
* no matching result implemented
* now filtering annotations that are orphaned
* filter object results without valid paths
* add progress bar
* added e2e tests
* removed extraneous click
* fix typos
* fix unit tests
* lint
* address pr comments
* fix tests
* fix tests, centralize logic to object api, check for root instead
* remove debug statement
* lint
* fix documentation
* lint
* fix doc
* made some optimizations after talking with akhenry
* fix test
* update docs
* fix docs
* Have in-memory search indexer use composition API (#5578)
* need to remove tags and objects on composition removal
* had to separate out emits from load as it was causing memory indexer to loop upon itself
* Add parsing for areIdsEqual util to consistently remove folders (#5589)
* Add parsing util to identifier for ID comparison
* Moved firstIdentifier to top of function
* Lint fix
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Revert "Have in-memory search indexer use composition API (#5578)" (#5609)
This reverts commit 7cf11e177c6c48093a6b37902ba3dfb36414ff10.
* [e2e] Tests for Display Layout and LAD Tables and telemetry (#5607)
* Check for circular references in originalPath - 5615 (#5619)
* check for circular references
* add test
* fix test
* address PR comments by making comments better
* fix docs...again
* Update version number
* Prevent cyclic references in link & move actions (#5635)
* do not create circular refs
* add negative validation test
* move to plugin
* add link test too
* fix docs
* refactored per john request
* fix path
* use appAction lib
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* [Condition Set] Add check for empty string being passed to the makeKeyString util by TelemetryCriterion (#5636) (#5663)
* Check telemetry is defined before using makeKeyString util
* Add optional chaining in the check
* Add e2e test
* Add check for undefined
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
* [Fault Management] New Example Provider, Unit and e2e tests (#5579)
* added unit tests for fault management plugin
* modified the example fault provider to work out of the box
* updating for new e2e folder structure
* part of the e2e tests
* WIP
* Imagery thumbnail regression fixes - 5327 (#5569)
* Add an active class to thumbnail to indicate current focused image
* Differentiate bg color between real-time and fixed
* scrollIntoView inline: center
* Added watcher for bounds change to trigger thumbnail scroll
* Resolve merge conflict with requestHistory change to telemetry collection
* Split thumbnail into sub component
* Monitor isFixed value to unpause playback status
* updated search to include name, namespace and description added some more e2e tests
* added rest of e2e tests
* fixed my init script, had to disable lint for no-force because it was not working without it, saw online this may be a pw bug
* fix: removing maelstrom theme from application (#5600)
* added some tests for no faults
* visual tests
* added visual tests for fault management
* created utils file for shared functionality between function and visual tests
* updating to 2.0.8
* tryin to remove imagery changes from master
* trying to trigger a refresh
* tryin to refresh
* updated search to include name, namespace and description added some more e2e tests
* added rest of e2e tests
* fix: removing maelstrom theme from application (#5600)
* fixed my init script, had to disable lint for no-force because it was not working without it, saw online this may be a pw bug
* added some tests for no faults
* visual tests
* added visual tests for fault management
* created utils file for shared functionality between function and visual tests
* updating to 2.0.8
* no clue
* still no clue
* removing imports and chaning to requires
* updating utils file to work with require
* fixing paths
* fixing a test I had messed up when adding static exmaple faults
* ONE LAST PATH FIX... hopefully
* typo in files fix
* fix folder typo
* thought I got this one, but apparently not, well I did now! who is laughing now!?
Co-authored-by: Michael Rogers <contact@mhrogers.com>
Co-authored-by: Vitor Henckel <vitor@henckel.com.br>
* Sort tree items locally on rename (#5643)
* fix typo
* Sort the tree items locally on object rename
* Use the navigationPath as a key
- This ensures that objects AND linked objects will be sorted
* add 'tree' and 'treeitem' roles to mct-tree
* WIP tree item reordering test
* Select the first object that matches
* Test that all object links are also reordered
* Get the final uuid before queryParams as notebook sections have uuids
* Make `openObjectTreeContextMenu` more deterministic and update usage
* Add `expandPathToTreeItem` and `expandTreeItemByName` appActions
* add `#tree-pane` id for the tree view
* Add tree visual component test suite and bump percy-cli
* Remove tree appActions
* Better variable name
Co-authored-by: Scott Bell <scott@traclabs.com>
* Mct5549 fix indexer composition error (#5610)
* [Display Layout] Composition and configuration sync (#5669)
LGTM
* [e2e] Stabilize notebook tag tests (#5681)
* Use more deterministic selector
* Hover first to "slow down" e2e actions while in headless mode
* Moves condition set fix into 2.0.8 (#5673)
* Set Focused Image index after a imagery is selected from a timestrip - 5632 (#5664)
* Set focused image when timestamp prop is passed in
* Unused var
* Create timestrip with imagery child
* Add equality check for hovered image and view large image url
* Cleanup
* Time List 5534 for release/2.0.8 (#5678)
* Changes to Time List view. Closes #5534.
- Compacted table row spacing.
- Set all timeframes to display by default when creating a new Time List.
- Removed 'Upload plan' file button from properties.
* Changes to Time List view. Closes #5534.
- Better hint text for editing Timeframe Inspector section.
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* [CI] Enable couchdb e2e testing in open source (#5655)
* Handle couch db not found errors so that interceptors are still invoked. (#5654)
* Fix tests for interceptors
* [e2e] Add test for 'mine' folder initialization
* [e2e] don't fail on expected console errors
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
* [Docs] Update CouchDB local install documentation (#5692)
* Update local CouchDB install docs to include docker workflow
* reformat to source configuration scripts where possible
* correct couchdb case
Co-authored-by: John Hill <john.c.hill@nasa.gov>
* [Time Conductor] History not working correctly (#5687)
* the check for fixed time vs realtime was not updating, have fixed this
* merging in related changes from master pr #4414
* lint fixes
* Update src/plugins/timeConductor/ConductorHistory.vue
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* setting time mode directly on load
* fixing issue where realtime history was being wiped on reloads while viewing fixed time
* formatting
* stubbed in some tests
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* Only index if provider does not support search - mct5690 (#5693)
* only index if provider does not support search
* add some tests
* fix tests
* [e2e] Add search couchdb test for duplicates
* [e2e] Modify existing search test instead
* lint
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
* Don't re-request historical data on ticks (#5701)
Don't rerequest telemetry on ticks.
* Fix duplicate declaration from merge
Co-authored-by: Michael Rogers <contact@mhrogers.com>
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Charles Hacskaylo <charlesh88@gmail.com>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: Alize Nguyen <alizenguyen@gmail.com>
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Vitor Henckel <vitor@henckel.com.br>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
2022-08-24 18:08:17 +00:00
await page . locator ( '.c-imagery-tsv-container' ) . hover ( ) ;
2023-01-21 19:25:35 +00:00
// Get the img src of the hovered image thumbnail
const hoveredThumbnailImg = page . locator (
'.c-imagery-tsv div.c-imagery-tsv__image-wrapper:hover img'
) ;
const hoveredThumbnailImgSrc = await hoveredThumbnailImg . getAttribute ( 'src' ) ;
// Verify that imagery timestrip view uses the thumbnailUrl as img src for thumbnails
expect ( hoveredThumbnailImgSrc ) . toBeTruthy ( ) ;
expect ( hoveredThumbnailImgSrc ) . toMatch ( thumbnailUrlParamsRegexp ) ;
// Click on the hovered thumbnail to open "View Large" view
Merge `release/2.0.8` into `master` (#5709)
* Imagery thumbnail regression fixes - 5327 (#5591)
* Add an active class to thumbnail to indicate current focused image
* Differentiate bg color between real-time and fixed
* scrollIntoView inline: center
* Added watcher for bounds change to trigger thumbnail scroll
* Resolve merge conflict with requestHistory change to telemetry collection
* Split thumbnail into sub component
* Monitor isFixed value to unpause playback status
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
* [e2e] Improve appActions (#5592)
* update selectors to use aria labels
* Update appActions
- Create new function `getHashUrlToDomainObject` to get the browse url to a given object given its uuid
- Create new function `getFocusedObjectUuid`... self explanatory :)
- Update `createDomainObjectWIthDefaults` to make use of the new url generation
- Update `createDomainObject...`'s arguments to be more organized, and accept a parent object
- Update some docs, still need to clarify some
* Update appActions e2e tests
- Refactor for organization
- Test our new appActions in one go
* Update existing usages of `createDomainObject...` to match the new API
* fix accidental renamed export
* Fix jsdoc return types
* refactor telemetryTable test to use appActions
* Improve selectors
* Refactor test
* improve selector
* add clock mode appActions
* lint
* Fix jsdoc
* Code review comments
* mark failing visual tests as fixme temporarily
* Update package.json (#5601)
* Fix menu style in Snow theme (#5557)
* Include the plan source map when generating the time list/plan hybrid object (#5604)
* Search should indicate in progress and no results states, filter orphaned results (#5599)
* no matching result implemented
* now filtering annotations that are orphaned
* filter object results without valid paths
* add progress bar
* added e2e tests
* removed extraneous click
* fix typos
* fix unit tests
* lint
* address pr comments
* fix tests
* fix tests, centralize logic to object api, check for root instead
* remove debug statement
* lint
* fix documentation
* lint
* fix doc
* made some optimizations after talking with akhenry
* fix test
* update docs
* fix docs
* Have in-memory search indexer use composition API (#5578)
* need to remove tags and objects on composition removal
* had to separate out emits from load as it was causing memory indexer to loop upon itself
* Add parsing for areIdsEqual util to consistently remove folders (#5589)
* Add parsing util to identifier for ID comparison
* Moved firstIdentifier to top of function
* Lint fix
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Revert "Have in-memory search indexer use composition API (#5578)" (#5609)
This reverts commit 7cf11e177c6c48093a6b37902ba3dfb36414ff10.
* [e2e] Tests for Display Layout and LAD Tables and telemetry (#5607)
* Check for circular references in originalPath - 5615 (#5619)
* check for circular references
* add test
* fix test
* address PR comments by making comments better
* fix docs...again
* Update version number
* Prevent cyclic references in link & move actions (#5635)
* do not create circular refs
* add negative validation test
* move to plugin
* add link test too
* fix docs
* refactored per john request
* fix path
* use appAction lib
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* [Condition Set] Add check for empty string being passed to the makeKeyString util by TelemetryCriterion (#5636) (#5663)
* Check telemetry is defined before using makeKeyString util
* Add optional chaining in the check
* Add e2e test
* Add check for undefined
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
* [Fault Management] New Example Provider, Unit and e2e tests (#5579)
* added unit tests for fault management plugin
* modified the example fault provider to work out of the box
* updating for new e2e folder structure
* part of the e2e tests
* WIP
* Imagery thumbnail regression fixes - 5327 (#5569)
* Add an active class to thumbnail to indicate current focused image
* Differentiate bg color between real-time and fixed
* scrollIntoView inline: center
* Added watcher for bounds change to trigger thumbnail scroll
* Resolve merge conflict with requestHistory change to telemetry collection
* Split thumbnail into sub component
* Monitor isFixed value to unpause playback status
* updated search to include name, namespace and description added some more e2e tests
* added rest of e2e tests
* fixed my init script, had to disable lint for no-force because it was not working without it, saw online this may be a pw bug
* fix: removing maelstrom theme from application (#5600)
* added some tests for no faults
* visual tests
* added visual tests for fault management
* created utils file for shared functionality between function and visual tests
* updating to 2.0.8
* tryin to remove imagery changes from master
* trying to trigger a refresh
* tryin to refresh
* updated search to include name, namespace and description added some more e2e tests
* added rest of e2e tests
* fix: removing maelstrom theme from application (#5600)
* fixed my init script, had to disable lint for no-force because it was not working without it, saw online this may be a pw bug
* added some tests for no faults
* visual tests
* added visual tests for fault management
* created utils file for shared functionality between function and visual tests
* updating to 2.0.8
* no clue
* still no clue
* removing imports and chaning to requires
* updating utils file to work with require
* fixing paths
* fixing a test I had messed up when adding static exmaple faults
* ONE LAST PATH FIX... hopefully
* typo in files fix
* fix folder typo
* thought I got this one, but apparently not, well I did now! who is laughing now!?
Co-authored-by: Michael Rogers <contact@mhrogers.com>
Co-authored-by: Vitor Henckel <vitor@henckel.com.br>
* Sort tree items locally on rename (#5643)
* fix typo
* Sort the tree items locally on object rename
* Use the navigationPath as a key
- This ensures that objects AND linked objects will be sorted
* add 'tree' and 'treeitem' roles to mct-tree
* WIP tree item reordering test
* Select the first object that matches
* Test that all object links are also reordered
* Get the final uuid before queryParams as notebook sections have uuids
* Make `openObjectTreeContextMenu` more deterministic and update usage
* Add `expandPathToTreeItem` and `expandTreeItemByName` appActions
* add `#tree-pane` id for the tree view
* Add tree visual component test suite and bump percy-cli
* Remove tree appActions
* Better variable name
Co-authored-by: Scott Bell <scott@traclabs.com>
* Mct5549 fix indexer composition error (#5610)
* [Display Layout] Composition and configuration sync (#5669)
LGTM
* [e2e] Stabilize notebook tag tests (#5681)
* Use more deterministic selector
* Hover first to "slow down" e2e actions while in headless mode
* Moves condition set fix into 2.0.8 (#5673)
* Set Focused Image index after a imagery is selected from a timestrip - 5632 (#5664)
* Set focused image when timestamp prop is passed in
* Unused var
* Create timestrip with imagery child
* Add equality check for hovered image and view large image url
* Cleanup
* Time List 5534 for release/2.0.8 (#5678)
* Changes to Time List view. Closes #5534.
- Compacted table row spacing.
- Set all timeframes to display by default when creating a new Time List.
- Removed 'Upload plan' file button from properties.
* Changes to Time List view. Closes #5534.
- Better hint text for editing Timeframe Inspector section.
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* [CI] Enable couchdb e2e testing in open source (#5655)
* Handle couch db not found errors so that interceptors are still invoked. (#5654)
* Fix tests for interceptors
* [e2e] Add test for 'mine' folder initialization
* [e2e] don't fail on expected console errors
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
* [Docs] Update CouchDB local install documentation (#5692)
* Update local CouchDB install docs to include docker workflow
* reformat to source configuration scripts where possible
* correct couchdb case
Co-authored-by: John Hill <john.c.hill@nasa.gov>
* [Time Conductor] History not working correctly (#5687)
* the check for fixed time vs realtime was not updating, have fixed this
* merging in related changes from master pr #4414
* lint fixes
* Update src/plugins/timeConductor/ConductorHistory.vue
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* setting time mode directly on load
* fixing issue where realtime history was being wiped on reloads while viewing fixed time
* formatting
* stubbed in some tests
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* Only index if provider does not support search - mct5690 (#5693)
* only index if provider does not support search
* add some tests
* fix tests
* [e2e] Add search couchdb test for duplicates
* [e2e] Modify existing search test instead
* lint
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
* Don't re-request historical data on ticks (#5701)
Don't rerequest telemetry on ticks.
* Fix duplicate declaration from merge
Co-authored-by: Michael Rogers <contact@mhrogers.com>
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Charles Hacskaylo <charlesh88@gmail.com>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: Alize Nguyen <alizenguyen@gmail.com>
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Vitor Henckel <vitor@henckel.com.br>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
2022-08-24 18:08:17 +00:00
await page . locator ( '.c-imagery-tsv-container' ) . click ( ) ;
2023-01-21 19:25:35 +00:00
// Get the img src of the large view image
Merge `release/2.0.8` into `master` (#5709)
* Imagery thumbnail regression fixes - 5327 (#5591)
* Add an active class to thumbnail to indicate current focused image
* Differentiate bg color between real-time and fixed
* scrollIntoView inline: center
* Added watcher for bounds change to trigger thumbnail scroll
* Resolve merge conflict with requestHistory change to telemetry collection
* Split thumbnail into sub component
* Monitor isFixed value to unpause playback status
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
* [e2e] Improve appActions (#5592)
* update selectors to use aria labels
* Update appActions
- Create new function `getHashUrlToDomainObject` to get the browse url to a given object given its uuid
- Create new function `getFocusedObjectUuid`... self explanatory :)
- Update `createDomainObjectWIthDefaults` to make use of the new url generation
- Update `createDomainObject...`'s arguments to be more organized, and accept a parent object
- Update some docs, still need to clarify some
* Update appActions e2e tests
- Refactor for organization
- Test our new appActions in one go
* Update existing usages of `createDomainObject...` to match the new API
* fix accidental renamed export
* Fix jsdoc return types
* refactor telemetryTable test to use appActions
* Improve selectors
* Refactor test
* improve selector
* add clock mode appActions
* lint
* Fix jsdoc
* Code review comments
* mark failing visual tests as fixme temporarily
* Update package.json (#5601)
* Fix menu style in Snow theme (#5557)
* Include the plan source map when generating the time list/plan hybrid object (#5604)
* Search should indicate in progress and no results states, filter orphaned results (#5599)
* no matching result implemented
* now filtering annotations that are orphaned
* filter object results without valid paths
* add progress bar
* added e2e tests
* removed extraneous click
* fix typos
* fix unit tests
* lint
* address pr comments
* fix tests
* fix tests, centralize logic to object api, check for root instead
* remove debug statement
* lint
* fix documentation
* lint
* fix doc
* made some optimizations after talking with akhenry
* fix test
* update docs
* fix docs
* Have in-memory search indexer use composition API (#5578)
* need to remove tags and objects on composition removal
* had to separate out emits from load as it was causing memory indexer to loop upon itself
* Add parsing for areIdsEqual util to consistently remove folders (#5589)
* Add parsing util to identifier for ID comparison
* Moved firstIdentifier to top of function
* Lint fix
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Revert "Have in-memory search indexer use composition API (#5578)" (#5609)
This reverts commit 7cf11e177c6c48093a6b37902ba3dfb36414ff10.
* [e2e] Tests for Display Layout and LAD Tables and telemetry (#5607)
* Check for circular references in originalPath - 5615 (#5619)
* check for circular references
* add test
* fix test
* address PR comments by making comments better
* fix docs...again
* Update version number
* Prevent cyclic references in link & move actions (#5635)
* do not create circular refs
* add negative validation test
* move to plugin
* add link test too
* fix docs
* refactored per john request
* fix path
* use appAction lib
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* [Condition Set] Add check for empty string being passed to the makeKeyString util by TelemetryCriterion (#5636) (#5663)
* Check telemetry is defined before using makeKeyString util
* Add optional chaining in the check
* Add e2e test
* Add check for undefined
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
* [Fault Management] New Example Provider, Unit and e2e tests (#5579)
* added unit tests for fault management plugin
* modified the example fault provider to work out of the box
* updating for new e2e folder structure
* part of the e2e tests
* WIP
* Imagery thumbnail regression fixes - 5327 (#5569)
* Add an active class to thumbnail to indicate current focused image
* Differentiate bg color between real-time and fixed
* scrollIntoView inline: center
* Added watcher for bounds change to trigger thumbnail scroll
* Resolve merge conflict with requestHistory change to telemetry collection
* Split thumbnail into sub component
* Monitor isFixed value to unpause playback status
* updated search to include name, namespace and description added some more e2e tests
* added rest of e2e tests
* fixed my init script, had to disable lint for no-force because it was not working without it, saw online this may be a pw bug
* fix: removing maelstrom theme from application (#5600)
* added some tests for no faults
* visual tests
* added visual tests for fault management
* created utils file for shared functionality between function and visual tests
* updating to 2.0.8
* tryin to remove imagery changes from master
* trying to trigger a refresh
* tryin to refresh
* updated search to include name, namespace and description added some more e2e tests
* added rest of e2e tests
* fix: removing maelstrom theme from application (#5600)
* fixed my init script, had to disable lint for no-force because it was not working without it, saw online this may be a pw bug
* added some tests for no faults
* visual tests
* added visual tests for fault management
* created utils file for shared functionality between function and visual tests
* updating to 2.0.8
* no clue
* still no clue
* removing imports and chaning to requires
* updating utils file to work with require
* fixing paths
* fixing a test I had messed up when adding static exmaple faults
* ONE LAST PATH FIX... hopefully
* typo in files fix
* fix folder typo
* thought I got this one, but apparently not, well I did now! who is laughing now!?
Co-authored-by: Michael Rogers <contact@mhrogers.com>
Co-authored-by: Vitor Henckel <vitor@henckel.com.br>
* Sort tree items locally on rename (#5643)
* fix typo
* Sort the tree items locally on object rename
* Use the navigationPath as a key
- This ensures that objects AND linked objects will be sorted
* add 'tree' and 'treeitem' roles to mct-tree
* WIP tree item reordering test
* Select the first object that matches
* Test that all object links are also reordered
* Get the final uuid before queryParams as notebook sections have uuids
* Make `openObjectTreeContextMenu` more deterministic and update usage
* Add `expandPathToTreeItem` and `expandTreeItemByName` appActions
* add `#tree-pane` id for the tree view
* Add tree visual component test suite and bump percy-cli
* Remove tree appActions
* Better variable name
Co-authored-by: Scott Bell <scott@traclabs.com>
* Mct5549 fix indexer composition error (#5610)
* [Display Layout] Composition and configuration sync (#5669)
LGTM
* [e2e] Stabilize notebook tag tests (#5681)
* Use more deterministic selector
* Hover first to "slow down" e2e actions while in headless mode
* Moves condition set fix into 2.0.8 (#5673)
* Set Focused Image index after a imagery is selected from a timestrip - 5632 (#5664)
* Set focused image when timestamp prop is passed in
* Unused var
* Create timestrip with imagery child
* Add equality check for hovered image and view large image url
* Cleanup
* Time List 5534 for release/2.0.8 (#5678)
* Changes to Time List view. Closes #5534.
- Compacted table row spacing.
- Set all timeframes to display by default when creating a new Time List.
- Removed 'Upload plan' file button from properties.
* Changes to Time List view. Closes #5534.
- Better hint text for editing Timeframe Inspector section.
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* [CI] Enable couchdb e2e testing in open source (#5655)
* Handle couch db not found errors so that interceptors are still invoked. (#5654)
* Fix tests for interceptors
* [e2e] Add test for 'mine' folder initialization
* [e2e] don't fail on expected console errors
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
* [Docs] Update CouchDB local install documentation (#5692)
* Update local CouchDB install docs to include docker workflow
* reformat to source configuration scripts where possible
* correct couchdb case
Co-authored-by: John Hill <john.c.hill@nasa.gov>
* [Time Conductor] History not working correctly (#5687)
* the check for fixed time vs realtime was not updating, have fixed this
* merging in related changes from master pr #4414
* lint fixes
* Update src/plugins/timeConductor/ConductorHistory.vue
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* setting time mode directly on load
* fixing issue where realtime history was being wiped on reloads while viewing fixed time
* formatting
* stubbed in some tests
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* Only index if provider does not support search - mct5690 (#5693)
* only index if provider does not support search
* add some tests
* fix tests
* [e2e] Add search couchdb test for duplicates
* [e2e] Modify existing search test instead
* lint
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
* Don't re-request historical data on ticks (#5701)
Don't rerequest telemetry on ticks.
* Fix duplicate declaration from merge
Co-authored-by: Michael Rogers <contact@mhrogers.com>
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Charles Hacskaylo <charlesh88@gmail.com>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: Alize Nguyen <alizenguyen@gmail.com>
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Vitor Henckel <vitor@henckel.com.br>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
2022-08-24 18:08:17 +00:00
const viewLargeImg = page . locator ( 'img.c-imagery__main-image__image' ) ;
const viewLargeImgSrc = await viewLargeImg . getAttribute ( 'src' ) ;
expect ( viewLargeImgSrc ) . toBeTruthy ( ) ;
2023-01-21 19:25:35 +00:00
// Verify that the image in the large view is the same as the hovered thumbnail
expect ( viewLargeImgSrc ) . toEqual ( hoveredThumbnailImgSrc . split ( '?' ) [ 0 ] ) ;
Merge `release/2.0.8` into `master` (#5709)
* Imagery thumbnail regression fixes - 5327 (#5591)
* Add an active class to thumbnail to indicate current focused image
* Differentiate bg color between real-time and fixed
* scrollIntoView inline: center
* Added watcher for bounds change to trigger thumbnail scroll
* Resolve merge conflict with requestHistory change to telemetry collection
* Split thumbnail into sub component
* Monitor isFixed value to unpause playback status
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
* [e2e] Improve appActions (#5592)
* update selectors to use aria labels
* Update appActions
- Create new function `getHashUrlToDomainObject` to get the browse url to a given object given its uuid
- Create new function `getFocusedObjectUuid`... self explanatory :)
- Update `createDomainObjectWIthDefaults` to make use of the new url generation
- Update `createDomainObject...`'s arguments to be more organized, and accept a parent object
- Update some docs, still need to clarify some
* Update appActions e2e tests
- Refactor for organization
- Test our new appActions in one go
* Update existing usages of `createDomainObject...` to match the new API
* fix accidental renamed export
* Fix jsdoc return types
* refactor telemetryTable test to use appActions
* Improve selectors
* Refactor test
* improve selector
* add clock mode appActions
* lint
* Fix jsdoc
* Code review comments
* mark failing visual tests as fixme temporarily
* Update package.json (#5601)
* Fix menu style in Snow theme (#5557)
* Include the plan source map when generating the time list/plan hybrid object (#5604)
* Search should indicate in progress and no results states, filter orphaned results (#5599)
* no matching result implemented
* now filtering annotations that are orphaned
* filter object results without valid paths
* add progress bar
* added e2e tests
* removed extraneous click
* fix typos
* fix unit tests
* lint
* address pr comments
* fix tests
* fix tests, centralize logic to object api, check for root instead
* remove debug statement
* lint
* fix documentation
* lint
* fix doc
* made some optimizations after talking with akhenry
* fix test
* update docs
* fix docs
* Have in-memory search indexer use composition API (#5578)
* need to remove tags and objects on composition removal
* had to separate out emits from load as it was causing memory indexer to loop upon itself
* Add parsing for areIdsEqual util to consistently remove folders (#5589)
* Add parsing util to identifier for ID comparison
* Moved firstIdentifier to top of function
* Lint fix
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Revert "Have in-memory search indexer use composition API (#5578)" (#5609)
This reverts commit 7cf11e177c6c48093a6b37902ba3dfb36414ff10.
* [e2e] Tests for Display Layout and LAD Tables and telemetry (#5607)
* Check for circular references in originalPath - 5615 (#5619)
* check for circular references
* add test
* fix test
* address PR comments by making comments better
* fix docs...again
* Update version number
* Prevent cyclic references in link & move actions (#5635)
* do not create circular refs
* add negative validation test
* move to plugin
* add link test too
* fix docs
* refactored per john request
* fix path
* use appAction lib
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* [Condition Set] Add check for empty string being passed to the makeKeyString util by TelemetryCriterion (#5636) (#5663)
* Check telemetry is defined before using makeKeyString util
* Add optional chaining in the check
* Add e2e test
* Add check for undefined
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
* [Fault Management] New Example Provider, Unit and e2e tests (#5579)
* added unit tests for fault management plugin
* modified the example fault provider to work out of the box
* updating for new e2e folder structure
* part of the e2e tests
* WIP
* Imagery thumbnail regression fixes - 5327 (#5569)
* Add an active class to thumbnail to indicate current focused image
* Differentiate bg color between real-time and fixed
* scrollIntoView inline: center
* Added watcher for bounds change to trigger thumbnail scroll
* Resolve merge conflict with requestHistory change to telemetry collection
* Split thumbnail into sub component
* Monitor isFixed value to unpause playback status
* updated search to include name, namespace and description added some more e2e tests
* added rest of e2e tests
* fixed my init script, had to disable lint for no-force because it was not working without it, saw online this may be a pw bug
* fix: removing maelstrom theme from application (#5600)
* added some tests for no faults
* visual tests
* added visual tests for fault management
* created utils file for shared functionality between function and visual tests
* updating to 2.0.8
* tryin to remove imagery changes from master
* trying to trigger a refresh
* tryin to refresh
* updated search to include name, namespace and description added some more e2e tests
* added rest of e2e tests
* fix: removing maelstrom theme from application (#5600)
* fixed my init script, had to disable lint for no-force because it was not working without it, saw online this may be a pw bug
* added some tests for no faults
* visual tests
* added visual tests for fault management
* created utils file for shared functionality between function and visual tests
* updating to 2.0.8
* no clue
* still no clue
* removing imports and chaning to requires
* updating utils file to work with require
* fixing paths
* fixing a test I had messed up when adding static exmaple faults
* ONE LAST PATH FIX... hopefully
* typo in files fix
* fix folder typo
* thought I got this one, but apparently not, well I did now! who is laughing now!?
Co-authored-by: Michael Rogers <contact@mhrogers.com>
Co-authored-by: Vitor Henckel <vitor@henckel.com.br>
* Sort tree items locally on rename (#5643)
* fix typo
* Sort the tree items locally on object rename
* Use the navigationPath as a key
- This ensures that objects AND linked objects will be sorted
* add 'tree' and 'treeitem' roles to mct-tree
* WIP tree item reordering test
* Select the first object that matches
* Test that all object links are also reordered
* Get the final uuid before queryParams as notebook sections have uuids
* Make `openObjectTreeContextMenu` more deterministic and update usage
* Add `expandPathToTreeItem` and `expandTreeItemByName` appActions
* add `#tree-pane` id for the tree view
* Add tree visual component test suite and bump percy-cli
* Remove tree appActions
* Better variable name
Co-authored-by: Scott Bell <scott@traclabs.com>
* Mct5549 fix indexer composition error (#5610)
* [Display Layout] Composition and configuration sync (#5669)
LGTM
* [e2e] Stabilize notebook tag tests (#5681)
* Use more deterministic selector
* Hover first to "slow down" e2e actions while in headless mode
* Moves condition set fix into 2.0.8 (#5673)
* Set Focused Image index after a imagery is selected from a timestrip - 5632 (#5664)
* Set focused image when timestamp prop is passed in
* Unused var
* Create timestrip with imagery child
* Add equality check for hovered image and view large image url
* Cleanup
* Time List 5534 for release/2.0.8 (#5678)
* Changes to Time List view. Closes #5534.
- Compacted table row spacing.
- Set all timeframes to display by default when creating a new Time List.
- Removed 'Upload plan' file button from properties.
* Changes to Time List view. Closes #5534.
- Better hint text for editing Timeframe Inspector section.
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* [CI] Enable couchdb e2e testing in open source (#5655)
* Handle couch db not found errors so that interceptors are still invoked. (#5654)
* Fix tests for interceptors
* [e2e] Add test for 'mine' folder initialization
* [e2e] don't fail on expected console errors
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
* [Docs] Update CouchDB local install documentation (#5692)
* Update local CouchDB install docs to include docker workflow
* reformat to source configuration scripts where possible
* correct couchdb case
Co-authored-by: John Hill <john.c.hill@nasa.gov>
* [Time Conductor] History not working correctly (#5687)
* the check for fixed time vs realtime was not updating, have fixed this
* merging in related changes from master pr #4414
* lint fixes
* Update src/plugins/timeConductor/ConductorHistory.vue
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* setting time mode directly on load
* fixing issue where realtime history was being wiped on reloads while viewing fixed time
* formatting
* stubbed in some tests
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* Only index if provider does not support search - mct5690 (#5693)
* only index if provider does not support search
* add some tests
* fix tests
* [e2e] Add search couchdb test for duplicates
* [e2e] Modify existing search test instead
* lint
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
* Don't re-request historical data on ticks (#5701)
Don't rerequest telemetry on ticks.
* Fix duplicate declaration from merge
Co-authored-by: Michael Rogers <contact@mhrogers.com>
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Charles Hacskaylo <charlesh88@gmail.com>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: Alize Nguyen <alizenguyen@gmail.com>
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Vitor Henckel <vitor@henckel.com.br>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
2022-08-24 18:08:17 +00:00
} ) ;
} ) ;
2022-06-11 13:45:09 +00:00
/ * *
2022-09-12 16:19:24 +00:00
* Perform the common actions and assertions for the Imagery View .
* This function verifies the following in order :
* 1. Can zoom in / o u t u s i n g t h e z o o m b u t t o n s
* 2. Can zoom in / o u t u s i n g t h e m o u s e w h e e l
* 3. Can pan the image using the pan hotkey + mouse drag
* 4. Clicking on the left arrow button pauses imagery and moves to the previous image
* 5. Imagery is updated as new images stream in , regardless of pause status
* 6. Old images are discarded when new images stream in
* 7. Image brightness / contrast can be adjusted by dragging the sliders
2022-06-11 13:45:09 +00:00
* @ param { import ( '@playwright/test' ) . Page } page
* /
2022-09-12 16:19:24 +00:00
async function performImageryViewOperationsAndAssert ( page ) {
2023-01-21 19:25:35 +00:00
// Verify that imagery thumbnails use a thumbnail url
const thumbnailImages = page . locator ( '.c-thumb__image' ) ;
const mainImage = page . locator ( '.c-imagery__main-image__image' ) ;
await expect ( thumbnailImages . first ( ) ) . toHaveAttribute ( 'src' , thumbnailUrlParamsRegexp ) ;
await expect ( mainImage ) . not . toHaveAttribute ( 'src' , thumbnailUrlParamsRegexp ) ;
2022-09-12 16:19:24 +00:00
// Click previous image button
const previousImageButton = page . locator ( '.c-nav--prev' ) ;
await previousImageButton . click ( ) ;
// Verify previous image
const selectedImage = page . locator ( '.selected' ) ;
await expect ( selectedImage ) . toBeVisible ( ) ;
// Use the zoom buttons to zoom in and out
await buttonZoomOnImageAndAssert ( page ) ;
// Use Mouse Wheel to zoom in to previous image
await mouseZoomOnImageAndAssert ( page , 2 ) ;
// Use alt+drag to move around image once zoomed in
await panZoomAndAssertImageProperties ( page ) ;
// Use Mouse Wheel to zoom out of previous image
await mouseZoomOnImageAndAssert ( page , - 2 ) ;
// Click next image button
const nextImageButton = page . locator ( '.c-nav--next' ) ;
await nextImageButton . click ( ) ;
2023-07-19 00:32:05 +00:00
// set realtime mode
await setRealTimeMode ( page ) ;
2022-09-12 16:19:24 +00:00
// Zoom in on next image
await mouseZoomOnImageAndAssert ( page , 2 ) ;
// Clicking on the left arrow should pause the imagery and go to previous image
await previousImageButton . click ( ) ;
await expect ( page . locator ( '.c-button.pause-play' ) ) . toHaveClass ( /is-paused/ ) ;
await expect ( selectedImage ) . toBeVisible ( ) ;
// The imagery view should be updated when new images come in
const imageCount = await page . locator ( '.c-imagery__thumb' ) . count ( ) ;
await expect
. poll (
async ( ) => {
const newImageCount = await page . locator ( '.c-imagery__thumb' ) . count ( ) ;
return newImageCount ;
} ,
{
message : 'verify that old images are discarded' ,
timeout : 7 * 1000
}
2023-05-18 21:54:46 +00:00
)
2022-09-12 16:19:24 +00:00
. toBe ( imageCount ) ;
// Verify selected image is still displayed
await expect ( selectedImage ) . toBeVisible ( ) ;
// Unpause imagery
await page . locator ( '.pause-play' ) . click ( ) ;
//Get background-image url from background-image css prop
await assertBackgroundImageUrlFromBackgroundCss ( page ) ;
// Open the image filter menu
await page . locator ( '[role=toolbar] button[title="Brightness and contrast"]' ) . click ( ) ;
// Drag the brightness and contrast sliders around and assert filter values
await dragBrightnessSliderAndAssertFilterValues ( page ) ;
await dragContrastSliderAndAssertFilterValues ( page ) ;
2022-06-11 13:45:09 +00:00
}
2022-06-13 22:24:44 +00:00
/ * *
* Drag the brightness slider to max , min , and midpoint and assert the filter values
* @ param { import ( '@playwright/test' ) . Page } page
* /
async function dragBrightnessSliderAndAssertFilterValues ( page ) {
const brightnessSlider = 'div.c-image-controls__slider-wrapper.icon-brightness > input' ;
const brightnessBoundingBox = await page . locator ( brightnessSlider ) . boundingBox ( ) ;
const brightnessMidX = brightnessBoundingBox . x + brightnessBoundingBox . width / 2 ;
const brightnessMidY = brightnessBoundingBox . y + brightnessBoundingBox . height / 2 ;
2023-05-18 21:54:46 +00:00
2022-06-30 18:50:47 +00:00
await page . locator ( brightnessSlider ) . hover ( { trial : true } ) ;
2022-06-13 22:24:44 +00:00
await page . mouse . down ( ) ;
await page . mouse . move ( brightnessBoundingBox . x + brightnessBoundingBox . width , brightnessMidY ) ;
await assertBackgroundImageBrightness ( page , '500' ) ;
await page . mouse . move ( brightnessBoundingBox . x , brightnessMidY ) ;
await assertBackgroundImageBrightness ( page , '0' ) ;
await page . mouse . move ( brightnessMidX , brightnessMidY ) ;
await assertBackgroundImageBrightness ( page , '250' ) ;
await page . mouse . up ( ) ;
}
/ * *
* Drag the contrast slider to max , min , and midpoint and assert the filter values
* @ param { import ( '@playwright/test' ) . Page } page
* /
async function dragContrastSliderAndAssertFilterValues ( page ) {
const contrastSlider = 'div.c-image-controls__slider-wrapper.icon-contrast > input' ;
const contrastBoundingBox = await page . locator ( contrastSlider ) . boundingBox ( ) ;
const contrastMidX = contrastBoundingBox . x + contrastBoundingBox . width / 2 ;
const contrastMidY = contrastBoundingBox . y + contrastBoundingBox . height / 2 ;
2023-05-18 21:54:46 +00:00
2022-06-30 18:50:47 +00:00
await page . locator ( contrastSlider ) . hover ( { trial : true } ) ;
2022-06-13 22:24:44 +00:00
await page . mouse . down ( ) ;
await page . mouse . move ( contrastBoundingBox . x + contrastBoundingBox . width , contrastMidY ) ;
await assertBackgroundImageContrast ( page , '500' ) ;
await page . mouse . move ( contrastBoundingBox . x , contrastMidY ) ;
await assertBackgroundImageContrast ( page , '0' ) ;
await page . mouse . move ( contrastMidX , contrastMidY ) ;
await assertBackgroundImageContrast ( page , '250' ) ;
await page . mouse . up ( ) ;
}
/ * *
* Gets the filter : brightness value of the current background - image and
* asserts against an expected value
* @ param { import ( '@playwright/test' ) . Page } page
* @ param { String } expected The expected brightness value
* /
async function assertBackgroundImageBrightness ( page , expected ) {
const backgroundImage = page . locator ( '.c-imagery__main-image__background-image' ) ;
// Get the brightness filter value (i.e: filter: brightness(500%) => "500")
const actual = await backgroundImage . evaluate ( ( el ) => {
return el . style . filter . match ( /brightness\((\d{1,3})%\)/ ) [ 1 ] ;
} ) ;
expect ( actual ) . toBe ( expected ) ;
}
2022-06-11 13:45:09 +00:00
/ * *
* @ param { import ( '@playwright/test' ) . Page } page
* /
async function assertBackgroundImageUrlFromBackgroundCss ( page ) {
const backgroundImage = page . locator ( '.c-imagery__main-image__background-image' ) ;
let backgroundImageUrl = await backgroundImage . evaluate ( ( el ) => {
return window
. getComputedStyle ( el )
. getPropertyValue ( 'background-image' )
. match ( /url\(([^)]+)\)/ ) [ 1 ] ;
} ) ;
let backgroundImageUrl1 = backgroundImageUrl . slice ( 1 , - 1 ) ; //forgive me, padre
console . log ( 'backgroundImageUrl1 ' + backgroundImageUrl1 ) ;
2023-05-18 21:54:46 +00:00
2022-06-11 13:45:09 +00:00
let backgroundImageUrl2 ;
await expect
. poll (
async ( ) => {
// Verify next image has updated
let backgroundImageUrlNext = await backgroundImage . evaluate ( ( el ) => {
return window
. getComputedStyle ( el )
. getPropertyValue ( 'background-image' )
. match ( /url\(([^)]+)\)/ ) [ 1 ] ;
} ) ;
backgroundImageUrl2 = backgroundImageUrlNext . slice ( 1 , - 1 ) ; //forgive me, padre
return backgroundImageUrl2 ;
} ,
{
message : 'verify next image has updated' ,
2022-09-12 16:19:24 +00:00
timeout : 7 * 1000
2022-06-11 13:45:09 +00:00
}
2023-05-18 21:54:46 +00:00
)
2022-06-11 13:45:09 +00:00
. not . toBe ( backgroundImageUrl1 ) ;
console . log ( 'backgroundImageUrl2 ' + backgroundImageUrl2 ) ;
}
/ * *
* @ param { import ( '@playwright/test' ) . Page } page
* /
async function panZoomAndAssertImageProperties ( page ) {
const imageryHintsText = await page . locator ( '.c-imagery__hints' ) . innerText ( ) ;
expect ( expectedAltText ) . toEqual ( imageryHintsText ) ;
2022-06-30 18:50:47 +00:00
const zoomedBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
2022-06-11 13:45:09 +00:00
const imageCenterX = zoomedBoundingBox . x + zoomedBoundingBox . width / 2 ;
const imageCenterY = zoomedBoundingBox . y + zoomedBoundingBox . height / 2 ;
2023-05-18 21:54:46 +00:00
2022-06-11 13:45:09 +00:00
// Pan right
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . down ( x ) ) ) ;
await page . mouse . down ( ) ;
await page . mouse . move ( imageCenterX - 200 , imageCenterY , 10 ) ;
await page . mouse . up ( ) ;
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . up ( x ) ) ) ;
2022-06-30 18:50:47 +00:00
const afterRightPanBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
2022-06-11 13:45:09 +00:00
expect ( zoomedBoundingBox . x ) . toBeGreaterThan ( afterRightPanBoundingBox . x ) ;
2023-05-18 21:54:46 +00:00
2022-06-11 13:45:09 +00:00
// Pan left
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . down ( x ) ) ) ;
await page . mouse . down ( ) ;
await page . mouse . move ( imageCenterX , imageCenterY , 10 ) ;
await page . mouse . up ( ) ;
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . up ( x ) ) ) ;
2022-06-30 18:50:47 +00:00
const afterLeftPanBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
2022-06-11 13:45:09 +00:00
expect ( afterRightPanBoundingBox . x ) . toBeLessThan ( afterLeftPanBoundingBox . x ) ;
2023-05-18 21:54:46 +00:00
2022-06-11 13:45:09 +00:00
// Pan up
await page . mouse . move ( imageCenterX , imageCenterY ) ;
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . down ( x ) ) ) ;
await page . mouse . down ( ) ;
await page . mouse . move ( imageCenterX , imageCenterY + 200 , 10 ) ;
await page . mouse . up ( ) ;
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . up ( x ) ) ) ;
2022-06-30 18:50:47 +00:00
const afterUpPanBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
2022-06-11 13:45:09 +00:00
expect ( afterUpPanBoundingBox . y ) . toBeGreaterThanOrEqual ( afterLeftPanBoundingBox . y ) ;
2023-05-18 21:54:46 +00:00
2022-06-11 13:45:09 +00:00
// Pan down
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . down ( x ) ) ) ;
await page . mouse . down ( ) ;
await page . mouse . move ( imageCenterX , imageCenterY - 200 , 10 ) ;
await page . mouse . up ( ) ;
await Promise . all ( panHotkey . map ( ( x ) => page . keyboard . up ( x ) ) ) ;
2022-06-30 18:50:47 +00:00
const afterDownPanBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
2022-06-11 13:45:09 +00:00
expect ( afterDownPanBoundingBox . y ) . toBeLessThanOrEqual ( afterUpPanBoundingBox . y ) ;
}
/ * *
2022-09-12 16:19:24 +00:00
* Use the mouse wheel to zoom in or out of an image and assert that the image
* has successfully zoomed in or out .
2022-06-11 13:45:09 +00:00
* @ param { import ( '@playwright/test' ) . Page } page
2022-09-12 16:19:24 +00:00
* @ param { number } [ factor = 2 ] The zoom factor . Positive for zoom in , negative for zoom out .
2022-06-11 13:45:09 +00:00
* /
2022-09-12 16:19:24 +00:00
async function mouseZoomOnImageAndAssert ( page , factor = 2 ) {
2022-06-11 13:45:09 +00:00
// Zoom in
const originalImageDimensions = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
const deltaYStep = 100 ; // equivalent to 1x zoom
2022-09-12 16:19:24 +00:00
await page . mouse . wheel ( 0 , deltaYStep * factor ) ;
2022-06-30 18:50:47 +00:00
const zoomedBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
2022-06-11 13:45:09 +00:00
const imageCenterX = zoomedBoundingBox . x + zoomedBoundingBox . width / 2 ;
const imageCenterY = zoomedBoundingBox . y + zoomedBoundingBox . height / 2 ;
2023-05-18 21:54:46 +00:00
2022-06-11 13:45:09 +00:00
// center the mouse pointer
await page . mouse . move ( imageCenterX , imageCenterY ) ;
2023-05-18 21:54:46 +00:00
2022-06-11 13:45:09 +00:00
// Wait for zoom animation to finish
2023-06-20 17:12:45 +00:00
await page . locator ( '.c-imagery__main-image__bg' ) . hover ( { trial : true } ) ;
2022-09-12 16:19:24 +00:00
const imageMouseZoomed = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
if ( factor > 0 ) {
expect ( imageMouseZoomed . height ) . toBeGreaterThan ( originalImageDimensions . height ) ;
expect ( imageMouseZoomed . width ) . toBeGreaterThan ( originalImageDimensions . width ) ;
} else {
expect ( imageMouseZoomed . height ) . toBeLessThan ( originalImageDimensions . height ) ;
expect ( imageMouseZoomed . width ) . toBeLessThan ( originalImageDimensions . width ) ;
}
}
/ * *
* Zoom in and out of the image using the buttons , and assert that the image has
* been successfully zoomed in or out .
* @ param { import ( '@playwright/test' ) . Page } page
* /
async function buttonZoomOnImageAndAssert ( page ) {
// Get initial image dimensions
const initialBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
// Zoom in twice via button
await zoomIntoImageryByButton ( page ) ;
await zoomIntoImageryByButton ( page ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
// Get and assert zoomed in image dimensions
const zoomedInBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
expect ( zoomedInBoundingBox . height ) . toBeGreaterThan ( initialBoundingBox . height ) ;
expect ( zoomedInBoundingBox . width ) . toBeGreaterThan ( initialBoundingBox . width ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
// Zoom out once via button
await zoomOutOfImageryByButton ( page ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
// Get and assert zoomed out image dimensions
const zoomedOutBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
expect ( zoomedOutBoundingBox . height ) . toBeLessThan ( zoomedInBoundingBox . height ) ;
expect ( zoomedOutBoundingBox . width ) . toBeLessThan ( zoomedInBoundingBox . width ) ;
2023-05-18 21:54:46 +00:00
2022-09-12 16:19:24 +00:00
// Zoom out again via button, assert against the initial image dimensions
await zoomOutOfImageryByButton ( page ) ;
const finalBoundingBox = await page . locator ( backgroundImageSelector ) . boundingBox ( ) ;
expect ( finalBoundingBox ) . toEqual ( initialBoundingBox ) ;
2022-06-11 13:45:09 +00:00
}
2.0.5 Backmerge (#5505)
* Bump d3-selection from 1.3.2 to 3.0.0
Bumps [d3-selection](https://github.com/d3/d3-selection) from 1.3.2 to 3.0.0.
- [Release notes](https://github.com/d3/d3-selection/releases)
- [Commits](https://github.com/d3/d3-selection/compare/v1.3.2...v3.0.0)
---
updated-dependencies:
- dependency-name: d3-selection
dependency-type: direct:development
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
* Remove snapshot
* Fix imagery filter slider drag in flexible layouts (#5326) (#5350)
* Dont' mutate a stacked plot unless its user initiated (#5357)
* Port grid icons and imagery test to release 2.0.5 from master (#5360)
* Port grid icons to release 2.0.5 from master
* Port imagery test to release/2.0.5
* Restrict timestrip composition to time based plots, plans and imagery (#5161)
* Restrict timestrip composition to time based plots, plans and imagery
* Adds unit tests for timeline composition policy
* Addresses review comments
Improves tests
* Reuse test objects
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
* Include objectStyles reference to conditionSetIdentifier in imports (#5354)
* Include objectStyles reference to conditionSetIdentifier in imports
* Add tests for export
* Refactored some code and removed console log
* Remove workarounds for chrome 'scrollTop' issue (#5375)
* Fix naming of method (#5368)
* Imagery View does not discard old images when they fall out of bounds (#5351)
* change to using telemetry collection
* fix tests
* added more unit tests
* Cherrypicked commits (#5390)
Co-authored-by: unlikelyzero <jchill2@gmail.com>
* [Timer] Update 3dot menu actions appropriately (#5387)
* Call `removeAllListeners()` after emit
* Manually show/hide actions if within a view
* remove sneaky `console.log()`
* Add Timer e2e test
* Add to comments
* Avoid hard waits in Timer e2e test
- Assert against timer view state instead of menu options
* Let's also test actions from the Timer view
* 5391 Add preview and drag support to Grand Search (#5394)
* add preview and drag actions
* added unit test, simplified remove action
* do not hide search results in preview mode when clicking outside search results
* add semantic aria labels to enable e2e tests
* readd preview
* add e2e test
* remove commented out url
* add percy snapshot and add search to ci
* make percy stuff work
* linting
* fix percy again
* move percy snapshots to a visual test
* added separate visual test and changed test to fixtures
* fix fixtures path
* addressing review comments
* 5361 tags not persisting locally (#5408)
* fixed typo
* remove unneeded lookup
* fix tags adding and deleting
* more reliable way to remove tags
* break tests up for parallel execution
* fixed notebook tagging test
* enable e2e tests
* made schedule index comment more clear and fix uppercase/lowercase issue
* address e2e changes
* add unit test to bump coverage
* fix typo
* need to check on annotation creation if provider exists or not
* added fixtures
* undo silly couchdb commit
* Plot progress bar fix for 2.0.5 (#5386)
* Add .bind(this) to stopLoading() in loadMoreData()
* Replace load spinner with progress bar for plots
* Add loading delay prop to swg
* fix linting errors
* match load order
* Update accessibility
* Add Math.max to timeout to handle negative inputs
* Moved math.max to load delay variable
* Add loading fix for stacked plots
* Move loadingUpdate func into plot item for update
* Merge conflict resolve
* Check if delay is 0 and send, put post in a func
* Put obj directly to model, removed computed prop
* Lint fix
* Fix template where legend was not displayed
* Remove commented out template
* Fixed failing test
Co-authored-by: unlikelyzero <jchill2@gmail.com>
* Make plans non editable. (#5377)
* Make plans non editable.
* Add unit test for fix
* [CouchDB] Better determination of indicator status (#5415)
* Add unknown state, remove maintenance state
* Handle all CouchDB status codes
- Set unknown status if we receive an unhandled code
* Include status code in error messages
* SharedWorker can send unknown status
* Add test for unknown status
* Gauge fixes for Firefox and units display (#5369)
* Closes #5323, #5325. Parent branch is release/2.0.5.
- Significant work refactoring SVG markup and CSS for dial gauge;
- Fixed missing `v-if` to control display of units for #5325;
- Fixed bad `.length` test for limit properties;
* Closes #5323, #5325
- Add 'value out of range' indicator
* Closes #5323, #5325
- More accurate element naming;
- Fix cross-browser problems with current value display in dial gauge;
- Refinements to "out of range" indicator approach;
- Fixed size of "Amplitude" input in Sine Wave Generator;
* Closes #5323, #5325
- Styles and stubbed in code to support needle meter type;
* Closes #5323, #5325
- Stubbed in markup and CSS for needle-style meter;
* Closes #5323, #5325
- Fixed missing `js-*` classes that were failing npm run test;
* Closes #5323, #5325
- Fix to not display meter value bar unless a data value is expected;
* Addressing PR comments
- Renamed method for clarity;
- Added null value check in method `valueExpected`;
* [Static Root] Return leafValue if null/undefined/false (#5416)
* Return leafValue if null/undefined/false
* Added a null to the test json
* Show a better default poll question (#5425)
* 5361 Tags not persisting when several notebook entries are created at once (#5428)
* add end to end test to catch multiple entry errors
* click expansion triangle instead
* fix race condition between annotation creation and mutation
* make sure notebook tags run in e2e
* address PR comments
* Handle missing objects gracefully (#5399)
* Handle missing object errors for display layouts
* Handle missing object errors for Overlay Plots
* Add check for this.config
* Add try/catch statement & check if obj is missing
* Changed console.error to console.warn
* Lint fix
* Fix for this.metadata.value is undefined
* Add e2e test
* Update comment text
* Add reload check and @private, verify console.warn
* Redid assignment and metadata check
* Fix typo
* Changed assignment and metadata check
* Redid checks for isMissing(object)
* Lint fix
* Backmerge e2e code coverage changes and fixes into release/2.0.5 (#5431)
* [Telemetry Collections] Respect "Latest" Strategy Option (#5421)
* Respect latest strategy in Telemetry Collections to limit potential memory growth.
* fix sourcemaps (#5373)
Co-authored-by: John Hill <john.c.hill@nasa.gov>
* Debounce status summary (#5448)
Co-authored-by: John Hill <john.c.hill@nasa.gov>
* No gauge (#5451)
* Installed gauge plugin by default
* Make gauge part of standard install in e2e suite and add restrictednotebook
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* [CouchDB] Always subscribe to the CouchDB changes feed (#5434)
* Add unknown state, remove maintenance state
* Handle all CouchDB status codes
- Set unknown status if we receive an unhandled code
* Include status code in error messages
* SharedWorker can send unknown status
* Add test for unknown status
* Always subscribe to CouchDB changes feed
- Always subscribe to the CouchDB changes feed, even if there are no observable objects, since we are also checking the status of CouchDB via this feed.
* Update indicator status if not using SharedWorker
* Start listening to changes feed on first request
* fix test
* adjust test to hopefully avoid race condition
* lint
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
* Fix for Fault Management Visual Bugs (#5376)
* Closes #5365
* General visual improvements
Co-authored-by: Charles Hacskaylo <charlesh88@gmail.com>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* fix pathing (#5452)
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* [Static Root] Static Root Plugin not loading (#5455)
* Log if hitting falsy leafValue
* Add some logging
* Remove logs and specify null/undefined
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* Allow endpoints with a single enum metadata value in Bar/Line graphs (#5443)
* If there is only 1 metadata value, set yKey to none. Also, fix bug for determining the name of a metadata value
* Update tests for enum metadata values
Co-authored-by: John Hill <john.c.hill@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* [Remote Clock] Wait for first tick and recalculate historical request bounds (#5433)
* Updated to ES6 class
* added request intercept functionality to telemetry api, added a request interceptor for remote clock
* add remoteClock e2e test stub
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Fix for missing object for LADTableSet (#5458)
* Handle missing object errors for display layouts
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* removing the call for default import now that TelemetryAPI is an ES6 class (#5461)
* [Remote Clock] Fix requestInterceptor typo (#5462)
* Fix typo in telemetry request interceptor
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Lock model (#5457)
* Lock event Model to prevent reactification
* de-reactify all the things
* Make API properties writable to allow test mocks to override them
* Fix merge conflict
* Added plot interceptor for missing series config (#5422)
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Shefali Joshi <simplyrender@gmail.com>
* Remove performance marks (#5465)
* Remove performance marks
* Retain performance mark in view large. It doesn't happen very often and it's needed for an automated performance test
* Use timeKey for time comparison (#5471)
* Fix couchdb no response (#5474)
* Update the creation date only when the document is created for the first time
* If there is no response from a bulk get, couch db has issues
* Check the response - if it's null, don't apply interceptors
* Fix shelved alarms (#5479)
* Fix the logic around shelved alarms
* Remove application router listener
* Release 2.0.5 UI and Gauge fixes (#5470)
* Various UI fixes
- Tweak to Gauge properties form for clarity and usability.
- Fix Gauge 'dial' type not obeying "Show units" property setting, closes #5325.
- Tweaks to Operator Status UI label and layout for clarity.
- Changed name and description of Graph object for clarity and consistency.
- Fixed CSS classing that was coloring Export menu items text incorrectly.
- Fixed icon-to-text vertical alignment in `.c-object-label`.
- Fix for broken layout in imagery local controls (brightness, layers, magnification).
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Stacked plot interceptor rename (#5468)
* Rename stacked plot interceptor and move to folder
Co-authored-by: Andrew Henry <akhenry@gmail.com>
* Clear data when time bounds are changed (#5482)
* Clear data when time bounds are changed
Also react to clear data action
Ensure that the yKey is set to 'none' if there is no range with array Values
* Refactor trace updates to a method
* get rid of root (#5483)
* Do not pass onPartialResponse option on to upstream telemetry (#5486)
* Fix all of the e2e tests (#5477)
* Fix timer test
* be explicit about the warnings text
* add full suite to CI to enable CircleCI Checks
* add back in devtool=false for CI env so firefox tests run
* add framework suite
* Don't install webpack HMR in CI
* Fix playwright version installs
* exclude HMR if running tests in any environment
- use NODE_ENV=TEST to exclude webpack HMR
- deparameterize some of the playwright configs
* use lower-case 'test'
* timer hover fix
* conditionally skip for firefox due to missing console events
* increase timeouts to give time for mutation
* no need to close save banner
* remove devtool setting
* revert
* update snapshots
* disable video to save some resources
* use one worker
* more timeouts :)
* Remove `browser.close()` and `page.close()` as it was breaking other tests
* Remove unnecessary awaits and fix func call syntax
* Fix image reset test
* fix restrictedNotebook tests
* revert playwright-ci.config settings
* increase timeout for polling imagery test
* remove unnecessary waits
* disable notebook lock test for chrome-beta as its unreliable
- remove some unnecessary 'wait for save banner' logic
- remove unused await
- mark imagery test as slow in chrome-beta
* LINT!! *shakes fist*
* don't run full e2e suite per commit
* disable video in all configs
* add flakey zoom comment
* exclude webpack HMR in non-development modes
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
* lint fix
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Joshi <simplyrender@gmail.com>
Co-authored-by: Jesse Mazzella <ozyx@users.noreply.github.com>
Co-authored-by: Jamie V <jamie.j.vigliotta@nasa.gov>
Co-authored-by: Andrew Henry <akhenry@gmail.com>
Co-authored-by: Scott Bell <scott@traclabs.com>
Co-authored-by: unlikelyzero <jchill2@gmail.com>
Co-authored-by: Alize Nguyen <alizenguyen@gmail.com>
Co-authored-by: Charles Hacskaylo <charlesh88@gmail.com>
Co-authored-by: Khalid Adil <khalidadil29@gmail.com>
Co-authored-by: rukmini-bose <48999852+rukmini-bose@users.noreply.github.com>
Co-authored-by: Jesse Mazzella <jesse.d.mazzella@nasa.gov>
2022-07-14 21:52:28 +00:00
/ * *
* Gets the filter : contrast value of the current background - image and
* asserts against an expected value
* @ param { import ( '@playwright/test' ) . Page } page
* @ param { String } expected The expected contrast value
* /
async function assertBackgroundImageContrast ( page , expected ) {
const backgroundImage = page . locator ( '.c-imagery__main-image__background-image' ) ;
// Get the contrast filter value (i.e: filter: contrast(500%) => "500")
const actual = await backgroundImage . evaluate ( ( el ) => {
return el . style . filter . match ( /contrast\((\d{1,3})%\)/ ) [ 1 ] ;
} ) ;
expect ( actual ) . toBe ( expected ) ;
}
2022-07-15 23:39:55 +00:00
/ * *
* Use the '+' button to zoom in . Hovers first if the toolbar is not visible
* and waits for the zoom animation to finish afterwards .
* @ param { import ( '@playwright/test' ) . Page } page
* /
async function zoomIntoImageryByButton ( page ) {
// FIXME: There should only be one set of imagery buttons, but there are two?
const zoomInBtn = page
. locator ( "[role='toolbar'][aria-label='Image controls'] .t-btn-zoom-in" )
. nth ( 0 ) ;
const backgroundImage = page . locator ( backgroundImageSelector ) ;
if ( ! ( await zoomInBtn . isVisible ( ) ) ) {
await backgroundImage . hover ( { trial : true } ) ;
}
2023-05-18 21:54:46 +00:00
2022-07-15 23:39:55 +00:00
await zoomInBtn . click ( ) ;
await waitForAnimations ( backgroundImage ) ;
}
/ * *
* Use the '-' button to zoom out . Hovers first if the toolbar is not visible
* and waits for the zoom animation to finish afterwards .
* @ param { import ( '@playwright/test' ) . Page } page
* /
async function zoomOutOfImageryByButton ( page ) {
// FIXME: There should only be one set of imagery buttons, but there are two?
const zoomOutBtn = page
. locator ( "[role='toolbar'][aria-label='Image controls'] .t-btn-zoom-out" )
. nth ( 0 ) ;
const backgroundImage = page . locator ( backgroundImageSelector ) ;
if ( ! ( await zoomOutBtn . isVisible ( ) ) ) {
await backgroundImage . hover ( { trial : true } ) ;
}
2023-05-18 21:54:46 +00:00
2022-07-15 23:39:55 +00:00
await zoomOutBtn . click ( ) ;
await waitForAnimations ( backgroundImage ) ;
}
/ * *
* Use the reset button to reset image pan and zoom . Hovers first if the toolbar is not visible
* and waits for the zoom animation to finish afterwards .
* @ param { import ( '@playwright/test' ) . Page } page
* /
async function resetImageryPanAndZoom ( page ) {
// FIXME: There should only be one set of imagery buttons, but there are two?
const panZoomResetBtn = page
. locator ( "[role='toolbar'][aria-label='Image controls'] .t-btn-zoom-reset" )
. nth ( 0 ) ;
const backgroundImage = page . locator ( backgroundImageSelector ) ;
if ( ! ( await panZoomResetBtn . isVisible ( ) ) ) {
await backgroundImage . hover ( { trial : true } ) ;
}
2023-05-18 21:54:46 +00:00
2022-07-15 23:39:55 +00:00
await panZoomResetBtn . click ( ) ;
await waitForAnimations ( backgroundImage ) ;
}
2023-06-16 22:14:38 +00:00
/ * *
* @ param { import ( '@playwright/test' ) . Page } page
* /
async function createImageryView ( page ) {
// Click the Create button
await page . click ( 'button:has-text("Create")' ) ;
// Click text=Example Imagery
await page . click ( 'li[role="menuitem"]:has-text("Example Imagery")' ) ;
// Clear and set Image load delay to minimum value
await page . locator ( 'input[type="number"]' ) . fill ( '' ) ;
await page . locator ( 'input[type="number"]' ) . fill ( '5000' ) ;
// Click text=OK
await Promise . all ( [
page . waitForNavigation ( { waitUntil : 'networkidle' } ) ,
page . click ( 'button:has-text("OK")' ) ,
//Wait for Save Banner to appear
page . waitForSelector ( '.c-message-banner__message' )
] ) ;
}