Test Vectors and .lvvect Files
- Updated2025-11-07
- 5 minute(s) read
A test vector is an array of input or expected values that you can assign to an input or output of the VI under test. You can use test vectors to assign multiple values to an input or output of the VI under test in a test case.
The Unit Test Framework Toolkit provides the following two types of test vectors:
You can edit test vectors by using the following methods:
- Using the Test Vector Properties - Edit dialog box.
- Using the front panel of a VI.
- Using third-party text editors.
Test Vector File Format
You can view and edit .lvvect files by using Microsoft Excel or a text editor.
The following table contains information about each component of a .lvvect file, including descriptions, default values, and notes:
| Component | Description | Default Value | Notes |
|---|---|---|---|
| LabVIEW Unit Test Framework | Header information that LabVIEW uses to identify test vectors that you created by using the Unit Test Framework Toolkit. | N/A | Do not modify. |
| Version | Header information that LabVIEW uses to identify the version of the Unit Test Framework Toolkit the test vector file was created in. | Automatic | Do not modify. |
| Library | Specifies the path to the LabVIEW class library (.lvclass) or the LabVIEW project library (.lvlib) the test vector file belongs to, if any. | Automatic | If the .lvvect file is located in the same drive as the library, use the relative path. Otherwise, use the absolute path. |
| Namespace | Specifies the name of the LabVIEW class library (.lvclass) or the LabVIEW project library (.lvlib) that the test vector file belongs to, if any. | Automatic | N/A |
| Include | Lists the test vector files that this test vector file includes. You can use these test vector files in a test. | Optional | N/A |
| Test Vector | Lists test vectors that belong to this test vector file. If you open this test vector file in Microsoft Excel, each column in this section indicates a test vector. | N/A | Refer to the table below for detailed information about each component of a test vector. |
LabVIEW automatically gathers and displays measurements when you create a test.
The following table contains information about each sub-component of a test vector in the Test Vector component of a test vector file:
| Row Number | Component | Description | Default Value | Note |
|---|---|---|---|---|
| 1 | Name | Specifies the name of a test vector. | <Blank> | N/A |
| 2 | Data Type | Specifies the data type of a test vector. | <Blank> | A test vector supports the following data types: I8, I16, I32, I64, U8, U16, U32, U64, Single Float, Double Float, Extended Float, Single Complex, Double Complex, Extended Complex, Enum U8, Enum U16, Enum U32, Enum U64, Boolean, String, Path. A test vector does not support the Array or Cluster data type but you can assign test vectors to elements of array or cluster controls of the VI under test or the setup VI on the Test Cases page of the Test Properties dialog box. |
| 3 | Append to | Specifies another test vector. LabVIEW adds the values of the specified test vector to the beginning of the current test vector, and moves the original values of the current test vector after these new values. | <Blank> | N/A |
| 4 | Requirement ID | Specifies the requirements ID of this test vector to use this test vector with NI Requirements Gateway. | <Blank> | N/A |
| 5 | Edit Type | Specifies the type of the test vector. | Sequence | N/A |
| 6 | Value Start | Indicates the beginning point of the test vector values. | Value Start | Do not modify. |
| 7 and Greater | Values | Specifies values of this test vector. | <Blank> | Each row between the Value Start row and the Value End row indicates a test vector value. |
| Last | Value End | Specifies the ending point of the test vector values. | Value End | You can insert rows above this row to add new test vector values. |
Example of a .lvvect File
The following figure shows an example of a test vector file:

You can add, edit, and remove test vectors by editing this test vector file in Microsoft Excel or a text editor.