/
Rule testing

Rule testing

Table of contents

Overview

In Leapfin, you can test your accounting and enrichment rules before merging them into production to ensure they impact your accounting records as intended. Implementing a consistent testing process as part of your rule-building will help maintain compliance, transparency, and accuracy in your accounting.

Leapfin offers two types of rule testing:

Test type

Description

Location

Test type

Description

Location

Unit testing

Assess the impact of your rules on a single accounting record.

Unit testing is facilitated from the accounting or enrichment rule page.

Data processing tests

Assess the impact of your rules against a larger sample of your accounting records.

Data processing tests are facilitated via the Data Processing Tests page.

The following sections detail both types of rule testing.

Unit testing

Unit testing, which is performed during the rule creation/editing workflow, allows you to assess the impact of your rules on a single accounting record. It is important to note that the results from your unit tests account for both your current rule and all active accounting and enrichment rules. This may cause your unit test to display changes that are not directly related to your current rule.

To perform a unit test:

  1. When creating/editing an accounting or enrichment rule, click RUN TEST.

image-20240828-185232.png
  1. Scroll to the Test results section at the bottom of the page.

  2. Select a record from the drop-down to view how it is impacted by your rule. The drop-down populates with all the accounting records contained within your test data set. If you need to add a record to test, click +TEST DATA.

Note: You do not have to re-run the test if you change test records from the drop-down.

image-20240828-185515.png
  1. View your test results under the following tabs in the Test results section:

    1. ACCOUNTING RECORD: Displays how your rules impact the standard fields, custom fields, and identifiers for your selected accounting record. Only enrichment rules will impact your accounting record data.

    2. JOURNAL ENTRIES: Displays how your rules impact the journal entries for the selected accounting record.

    3. LINKS: Displays how this rule would impact any linked records.

For both the accounting record and journal entry tabs, the PRIOR RESULT column displays the current state of the test data and the NEW RESULT column displays how this data would change if the rule was applied. All changes are highlighted in orange.

Data processing tests

Data processing tests allow you to assess the impact of your accounting and enrichment rules against a defined sample of your accounting records. They operate much like a live data processing run; however, they will not affect your live data. You can run a processing test for a single environment or compare the results between your sandbox and production environments. Leapfin recommends performing a data processing test before merging any sandbox changes into production to ensure your rules will operate as intended. Note: To ensure consistent test results, data processing tests do not account for locked periods.

Create a new data processing test

Follow the steps below to create a new data processing test:

  1. In the main navigation, navigate to the Data Processing Tests page.

  2. Click + NEW TEST.

  3. Input the following parameters for your data processing test:

    1. Name: The name of your test

    2. Date range: The date range for the data you want to test. These dates are based on the date the raw data was ingested into Leapfin.

    3. Data sample size: The sample size of the data you want to test from the date range. This will help reduce test processing times.

    4. Environment: The environment(s) you are testing. You have the option to select one test environment for which to view rule impact or a test environment and a comparison environment to view the differences in rule impact between the two environments. A common scenario is to test your production environment (test) against your sandbox environment (comparison).

  4. Click Create. Your new test will appear in the list with a Running status. The status will change to Success or Failed when the test is complete.

View the details of your completed data processing test

Under the Actions column, click the eye icon to view the details of your completed data processing test.

image-20240828-202615.png

The following diagram outlines the different sections of the test details page.

image-20240828-174113.png

A. Test details: Displays the owner, date range, and description for your test.

B. Test status: Displays the test status and the test sample size for each environment you are testing.

C. Environment select: Allows you to select the environment for which you want to view journal entry output based on your test. If you are comparing two environments, you can click Difference to view the difference in amounts between the two environments.

D. Results: Displays the total amounts for every account included in your test, organized by month and accounting side. You can click each row in the result section to view the accounting rules that impact the accounts. If you expand each rule, you can view sample accounting records that are impacted by the rule.

image-20240829-215759.png

 

Related content