-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #45 from TDT4290-group-4/37-test-sprint-1-code
37 test sprint 1 code
- Loading branch information
Showing
8 changed files
with
108 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,56 @@ | ||
| describe('Measurement tool', () => { | ||
| it('Places the measurement point', () => { | ||
| cy.visit('http://localhost:5173/#') | ||
|
|
||
| cy.get('#tools img[data-i18n="[title]tt.point_measurement"]').click() | ||
| cy.get('#potree_render_area canvas[tabindex="2222"]').click() | ||
|
|
||
| // Verify measurement was created | ||
| cy.get('#scene_object_properties').should('be.visible') | ||
| cy.get('#g_point_body').children().should('have.length.at.least', 1) | ||
| }) | ||
|
|
||
| it('Delete measurement point', function () { | ||
| cy.visit('http://localhost:5173/#') | ||
|
|
||
| cy.get('#tools img[data-i18n="[title]tt.point_measurement"]').click() | ||
| cy.get('#potree_render_area canvas[tabindex="2222"]').click() | ||
| cy.get('#scene_object_properties [name="remove"]').click() | ||
| cy.get('#tools img[data-i18n="[title]tt.point_measurement"]').click() | ||
| cy.get('#potree_render_area canvas[tabindex="2222"]').click() | ||
| cy.get('#g_point_body button.m-row-delete').click() | ||
| }) | ||
|
|
||
| it('Copy measurement point positions', function () { | ||
| cy.visit('http://localhost:5173/#') | ||
| cy.get('#tools img[data-i18n="[title]tt.point_measurement"]').click() | ||
| cy.get('#potree_render_area canvas[tabindex="2222"]').click() | ||
| cy.get('#scene_object_properties [name="copy"]').click() | ||
| }) | ||
|
|
||
| it('Switch between measurement points', function () { | ||
| cy.visit('http://localhost:5173/#') | ||
| // Create three point measurements | ||
| cy.get('#tools img[data-i18n="[title]tt.point_measurement"]').click() | ||
| cy.get('#potree_render_area canvas[tabindex="2222"]').click() | ||
| cy.get('#tools img[data-i18n="[title]tt.point_measurement"]').click() | ||
| cy.get('#potree_render_area canvas[tabindex="2222"]').click() | ||
| cy.get('#tools img[data-i18n="[title]tt.point_measurement"]').click() | ||
| cy.get('#potree_render_area canvas[tabindex="2222"]').click() | ||
| // Switch between the created points | ||
| cy.get('#g_point_body span[title="Point #2"]').click() | ||
| cy.get('#g_point_body div:nth-child(1)').click() | ||
| cy.get('#g_point_body span[title="Point #3"]').click() | ||
| }) | ||
|
|
||
| it('Open and close List of Measurements ', function () { | ||
| cy.visit('http://localhost:5173/#') | ||
|
|
||
| cy.get('#tools img[data-i18n="[title]tt.point_measurement"]').click() | ||
| cy.get('#potree_render_area canvas[tabindex="2222"]').click() | ||
| cy.get('#tools img[data-i18n="[title]tt.point_measurement"]').click() | ||
| cy.get('#potree_render_area canvas[tabindex="2222"]').click() | ||
| cy.get('#measurement_items span.m-group-title').click() | ||
| cy.get('#measurement_items span.m-group-title').click() | ||
| }) | ||
| }) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| describe('Shaded Lighting', () => { | ||
| it('Toggle the EDL checkbox on and off', () => { | ||
| cy.visit('http://localhost:5173/#') | ||
| cy.get('#chkEDLEnabled').uncheck().should('not.be.checked') | ||
| cy.get('#chkEDLEnabled').check().should('be.checked') | ||
| }) | ||
|
|
||
| it('Change radius', function () { | ||
| cy.visit('http://localhost:5173/#') | ||
| cy.get('div.potree_container').click() | ||
| cy.get('#sldEDLRadius span.ui-corner-all').click() | ||
| }) | ||
|
|
||
| it('Change strength', function () { | ||
| cy.visit('http://localhost:5173/#') | ||
| cy.get('#sldEDLStrength span.ui-corner-all').click() | ||
| cy.get('#sldEDLStrength span.ui-corner-all').click() | ||
| }) | ||
|
|
||
| it('Change opacity', function () { | ||
| cy.visit('http://localhost:5173/#') | ||
| cy.get('#sldEDLOpacity span.ui-corner-all').click() | ||
| cy.get('#sldEDLOpacity span.ui-corner-all').click() | ||
| }) | ||
| }) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters