# Test your mapping

Run the integration's test cases on a representative sandbox payload and correct any failed fields. You need GETS and country mappings for the country and transaction type you selected.

> **Before you start**
>
> Complete [GETS field mapping](https://docs.complyance.io/one-platform/developer-portal/integration-engine/gets-mapping/) and [country field mapping](https://docs.complyance.io/one-platform/developer-portal/integration-engine/country-mapping/) for this integration. Have a sample that includes the invoice details and any scenario-specific data your source will send. Use sandbox data; this check is not a production invoice submission.

## Step 1: Open the mapping’s test cases

Continue to **Testbed** in the integration setup flow. For a saved integration, select it in **Integration engine** and open its **Testbed**. Review the test cases shown for the selected country.

## Step 2: Run a representative payload

Select the appropriate sample in a test case’s payload selector, then choose **Run**. Repeat for the test cases applicable to your integration. Each case shows **Passed** or **Failed** when a result is available; check the case status rather than assuming that running it was successful.

## Step 3: Correct failed cases and retest

Open a failed case’s error details. Read its field, code (when shown) and message. Compare the mapped GETS field with the sample’s source value. Correct missing or invalid data in the source, or edit the matching GETS or country mapping, then choose **Retry** or run the case again. Repeat until the applicable cases pass.

When all displayed scenarios pass, the test flow confirms how many scenarios passed. Check the integration list’s test case counts as well. A passed sample confirms only what was tested: use a source associated with the mapping, and verify environment and credentials separately before sending live documents.

## If something goes wrong

**There is no payload to select:** return to **Payload Selection** and supply a representative sample for this country and transaction type.

**A mandatory field is missing:** match the reported field to the GETS or country field reference, add the missing source data, and map it before rerunning the case.

**A previously passed case now needs another run:** after changing a mapping or payload, rerun the applicable cases. Do not rely on results from an earlier version.

Next, [manage integrations](https://docs.complyance.io/one-platform/developer-portal/integration-engine/manage/) to review source assignment before using the mapping.

Source: https://docs.complyance.io/one-platform/developer-portal/integration-engine/test/
