> For the complete documentation index, see [llms.txt](https://funtest-1.gitbook.io/funtest-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://funtest-1.gitbook.io/funtest-documentation/creating-test-sequence/funtest-commands/test-result-export.md).

# Test Result Export

{% embed url="<https://www.youtube.com/watch?v=4IwnJ0gqF4E>" %}

## <mark style="color:blue;">#export (Export to file)</mark>

Using #export you can create CSV or PDF files to create custom test reports tailored for your application.

### Process:&#x20;

1. <mark style="color:blue;">**Create a tab called REPORT within the test file and create your test report template**</mark>

<figure><img src="/files/NSuam8RdxM3kTQYg11TT" alt=""><figcaption></figcaption></figure>

2. <mark style="color:blue;">**To populate it with test results from each run refer to the test cells from the TEST tab**</mark>

<figure><img src="/files/dR1tbd26CFX7P7WIpdlQ" alt=""><figcaption></figcaption></figure>

\
3\. <mark style="color:blue;">**In your test sequence export the REPORT sheet as PDF or CSV**</mark>

PDF Example

*Export PDF from sheet "LABEL", range A1 to G30 to the file "Test\_Report.pdf", located in project's directory.*

<table data-full-width="true"><thead><tr><th width="141">Command<select><option value="69d37e59dbc44aaca6dc72161f84784b" label="#msg" color="blue"></option><option value="b928d283a7784fae8c94f7bc27467b23" label="#dlg" color="blue"></option><option value="dd3ea796575b44beb6fe421f4c920096" label="#goto" color="blue"></option><option value="1576fb8a623240f6a5cd19b0086ec379" label="#return" color="blue"></option><option value="5d7a98d7acab42ebae94f38253cd4252" label="#throw" color="blue"></option><option value="6c4f0bb0151b47dfba70bb09cbe953b1" label="#onerror" color="blue"></option><option value="4456763d3e2e4df9a8fe186c05a233d0" label="#onfail" color="blue"></option><option value="1fb65c562db94959b92fecd477c64baa" label="#catchio" color="blue"></option><option value="245770ec76da438ba7f63acf8dcd0c35" label="#oninput" color="blue"></option><option value="1e7166534c554904b78c14f6e2424e52" label="#export" color="blue"></option></select></th><th>Parameter</th></tr></thead><tbody><tr><td><span data-option="1e7166534c554904b78c14f6e2424e52">#export</span></td><td>pdf:sheet="REPORT":range=A1:to=G30:path="$project-dir$\Test_Report.pdf"</td></tr></tbody></table>

4. <mark style="color:blue;">**View PDF**</mark><br>

   <figure><img src="/files/n0aFgkBtjgQANNihrbik" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
The same process would follow for exporting to CSV file
{% endhint %}

## <mark style="color:blue;">#statrec (Basic statistics record)</mark>

This command is to create statistics record from each test execution and store it in one file location to enable test station monitoring.

Process

1. In the STAT tab define what values you want to save from each test run. In the first row define header and in the second row refer the results from the TEST tab (same process as creating test report above)<br>

   <figure><img src="/files/nkwrI0TwPTwOYyUT7nE9" alt=""><figcaption></figcaption></figure>

2. In your test sequence use #statrect command to append current test result to a csv file\
   &#x20;

   **Example**

   Create a default (daily) statistic file in the project's "statfiles" sub-directory. The name will be "Dyyyy-MMdd< test-file>.csv", where "yyyy" is the year, "MM" month, "dd" day and "test-file" is the currently opened test-file. Every day a new-one will be created.

   <table data-full-width="true"><thead><tr><th width="141">Command<select><option value="69d37e59dbc44aaca6dc72161f84784b" label="#msg" color="blue"></option><option value="b928d283a7784fae8c94f7bc27467b23" label="#dlg" color="blue"></option><option value="dd3ea796575b44beb6fe421f4c920096" label="#goto" color="blue"></option><option value="1576fb8a623240f6a5cd19b0086ec379" label="#return" color="blue"></option><option value="5d7a98d7acab42ebae94f38253cd4252" label="#throw" color="blue"></option><option value="6c4f0bb0151b47dfba70bb09cbe953b1" label="#onerror" color="blue"></option><option value="4456763d3e2e4df9a8fe186c05a233d0" label="#onfail" color="blue"></option><option value="1fb65c562db94959b92fecd477c64baa" label="#catchio" color="blue"></option><option value="245770ec76da438ba7f63acf8dcd0c35" label="#oninput" color="blue"></option><option value="1e7166534c554904b78c14f6e2424e52" label="#export" color="blue"></option><option value="f6dfb045b1af49a68163d8801d5977f8" label="#statrec" color="blue"></option></select></th><th>Parameter</th></tr></thead><tbody><tr><td><span data-option="f6dfb045b1af49a68163d8801d5977f8">#statrec</span></td><td>&#x3C;none></td></tr></tbody></table>

3. View Result in CSV file and perform analysis<br>

   <br>

   <figure><img src="/files/fmYdfRcqprWvNH1FA7Su" alt=""><figcaption></figcaption></figure>

## <mark style="color:blue;">#AMSTAT (Automated Statistics)</mark>

**Coming Soon**
