Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added tests for component checkout api endpoint #15864

Merged
merged 1 commit into from
Nov 21, 2024

Conversation

marcusmoore
Copy link
Collaborator

Description

This PR adds tests for the api endpoint for component checkouts.

Type of change

  • Testing

@marcusmoore marcusmoore requested a review from snipe as a code owner November 20, 2024 23:36
Copy link

what-the-diff bot commented Nov 20, 2024

PR Summary

  • Introduction of a New Test File for Component Checkout
    A new test file named ComponentCheckoutTest.php has been included to ensure the component checkout feature runs effectively. It covers aspects such as authority checks for checkout actions, handling of components that don't exist, requirement checking for necessary fields during checkout, restricting checkout quantities based on stock availability, recording checkout activities in the database and support for requests that involve multiple companies in a checkout.

  • Improvements to CustomTestMacros.php
    The file CustomTestMacros.php has been upgraded with a new function assertPayloadContains. This new function verifies the existence of certain keys within the response data, which confirms that the response contains the expected information.

@snipe snipe merged commit e05f443 into snipe:develop Nov 21, 2024
9 checks passed
@marcusmoore marcusmoore deleted the testing/api-component-checkout branch November 21, 2024 18:14
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.

2 participants