Skip to content

AB#107240 added an export of the full test path URL so it doesnt have… - #11

Merged
lardo-de-arnaud merged 5 commits into
masterfrom
AB#107240
Nov 14, 2025
Merged

AB#107240 added an export of the full test path URL so it doesnt have…#11
lardo-de-arnaud merged 5 commits into
masterfrom
AB#107240

Conversation

@lardo-de-arnaud

Copy link
Copy Markdown
Contributor

… to be done in the LTI tool

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds a new utility function getTestUrl() to the deployment-test-utils package, which constructs and exports the full test path URL from environment variables CANVAS_HOST and DEPLOYMENT_TEST_PATH. This eliminates the need for consuming LTI tools to manually construct URLs, simplifying test setup.

Key Changes:

  • Added URL normalization logic that trims whitespace and handles trailing/leading slashes consistently
  • Exported a new getTestUrl() function that returns the pre-computed URL or undefined if the host is not set

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/testUtils.js Outdated
Comment thread src/testUtils.js Outdated
Comment thread src/testUtils.js Outdated
Comment thread src/testUtils.js Outdated
lardo-de-arnaud and others added 2 commits November 14, 2025 13:20
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@sebastianchristopher

Copy link
Copy Markdown
Contributor

I wonder whether it's worth writing these back to process.env for the runtime duration - that way you can still import process.env.CANVAS_HOST into tests and it will be normalized?

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 1 out of 1 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/testUtils.js Outdated
Comment thread src/testUtils.js Outdated
Comment thread src/testUtils.js Outdated
Comment thread src/testUtils.js Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@lardo-de-arnaud
lardo-de-arnaud merged commit 3b9449d into master Nov 14, 2025
7 checks passed
@lardo-de-arnaud
lardo-de-arnaud deleted the AB#107240 branch November 14, 2025 17:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants