Testing B2B functionality
Importing and syncing product catalogue
The category hierarchy and the products catalogue are built from data retrieved from the ERP.
Testable by inspecting a product category for accuracy of:
- listed SKUs / item numbers
- product images
- descriptions
- categorization
Managing users
User accounts are managed by Carlstar teams via API.
Create user
Testable by making API calls described in the Create User section of the Manage Users chapter.
In the case of this action email confirmations sent to the registered customer’s email address and to the configured customer services email address.
Modify user
Testable by making API calls described in the Modify User section of the Manage Users chapter.
Disable user
Testable by making API calls described in the Disable User section of the Manage Users chapter.
Enable user
Testable by making API calls described in the Enable User section of the Manage Users chapter.
Delete user
Testable by making API calls described in the Delete User section of the Manage Users chapter.
Product Finder
Login required
As only logged-in users can access the product finder the following should be tested:
- for not logged-in users only the login form should be visible
- after successful login the product finder UI became visible
Search by properties
Testable by initiating search with one or a combination of properties and inspect the products in the search results table.
Search by SKU
Testable by initiating search with one or more SKU numbers and inspect the products in the result table. Only products that match the specified SKUs should be in the table.
Select location
The following should be tested:
- the location select dropdown should not be visible until a search is made after the page loaded
- after selecting a location the results table should refresh and display inventory and pricing only for the selected location
- after selecting a location the location dropdown should display the value and should be in a disabled state - meaning it’s not possible to open it
- after selecting a value, the “Reset location” button should be visible next to the location dropdown field
Selected location is persistent
The selected location is stored as a browser localStorage property, meaning that it is saved across browser sessions. The browser only erase it if the user explicitly reset the selected location on the product finder page.
Navigate away and revisit the product finder
Select a location than navigate away and revisit the product finder page. After making a new search:
- the location search should be visible
- the previously selected location should be automatically preselected in the dropdown and the dropdown should be in a disabled state
- the reset location button should be visible
- the results table rows should only contain inventory and pricing data for the selected location
Close browser and revisit product finder
As mentioned above the user selected location is persistent / saved across browser sessions. So closing and opening the browser (destroying and creating a new browser session) should not affect the location value.
Select a location than navigate away and revisit the product finder page. When making a new search:
- the location search should be visible
- the previously selected location should be automatically preselected in the dropdown and the dropdown should be in a disabled state
- the reset location button should be visible
- the results table rows should only contain inventory and pricing data for the selected location
Obviously if no location was selected before closing the browser than no location will be pre selected in the new session.
Reset location
The following should be tested:
- if no location was set previously than when the location dropdown appears after the initial search the reset location button is not visible
- it should appear when the user selects any location from the dropdown
- if the user navigates away after selected a location but later revisits the products finder page and makes a search the location dropdown should appear with the previously selected location AND with a visible reset location button
- when clicked a confirmation modal should appear that informs tha user the the cart content will be erased
- if the user cancels this confirmation nothing happens
- if the user okays the warning than
- the cart is emptied
- the location dropdown resets to it’s default value
- the results table refreshes reflecting the location change
Add to order request
The following should be tested:
- the add to order button in each row of the results table should be in a disabled (non clickable) state until a location is selected
- if location is not selected the disabled buttons should display an explanation when the mouse cursor hovers over it
- after selecting a location the refreshed results table should contain anabled state (clickable) buttons
- when an enabled button is clicked it should change into disabled state and the text should change to “Adding” with a loading animation before it.
- when the product is added to the order successfully
- the button’s text should change to “Added” and revert back to “Add” after 1 second.
- after this 1 second timeout the button should be in an enabled state again
- parallel with this a toast (a small pop-up) should appear in the top right corner of the windows with a checkmark icon and message: “Added successfully.”. It should disappear after a 5 seconds timeout.
Order submission
The order request submission page can be reached by clicking the cart icon in the site header.
This page should contain the following components:
- a cart table listing the added products
- a block displaying information about the logged in user’s company
- shipping address selection dropdown
- additional, optional information blocks for:
- adding a requested delivery date field with date selector
- external PO number
- a textarea for any additional comment about the order for the sales team
Submission
After submitting the request the customer should be redirected to the order received conformation page.
Check emails
After the order request saved to the database the following emails are sent:
- new order notification with the order details to the site owner
- this email should also have an ERP importable CSV file attachment with the order data
- order confirmation with the order details to the customer
Check order history in account
The new order should be visible in the customers user account under the Orders section.
User Account
Logging into the user account the following should be visible in the sidebar:
- company name
- user’s email and phone number
- navigation menu with the following links:
- dashboard
- orders
- addresses
- documents
- change password
- security
- delete my account
- logout
Login / logout
For non logged in users the account page should display a login form. After a successful login the user’s account dashboard should load.
After logging out the users should stay on the account pageL but should be presented with the login form because of the logged out status.
Check address list
This section should list all the shipping addresses that are registered in the Navision ERP for the user’s CustomerNo.
Check orders
This section should list all the orders placed by the account.
If the logged in user belongs to a Carlstar partner company that has multiple B2B users than the order list contains all the orders placed by the company users.
Check documents
This section should list all the uploaded documents for the partner company CustomerNo.
Change password
This page should display the password change form with the following input fields:
- current password
- new password
- new password conformation
Enable / disable 2FA
- For users with non enabled 2FA this page should display the steps for enabling the two-factor authentication.
- For users with enabled 2FA this page should display options for
- deactivating 2FA
- regenerating 2FA backup codes
Users with activated
Request account closure
This page should display an information block about account closure and a buton to initiate the request.
- Clicking the button should disable the account and redirect the user to a confirmation page.
- After this the log in should not work for the user account.
- The Carlstar sales team should receive an email notification about the delete request.