# ExUnit

<figure><img src="https://1326643208-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FnpMhTPhBTwVaw7bZVBjY%2Fuploads%2FG4VFsLZaRgdX0KtfeV2m%2FElixir_programming_language_logo.svg?alt=media&#x26;token=7cd7664d-d31b-4e29-b396-4c10627ab809" alt=""><figcaption></figcaption></figure>

ExUnit. Elixir's built-in test framework is ExUnit and it includes everything we need to thoroughly test our code. Before moving on it is important to note that tests are implemented as Elixir scripts so we need to use the . exs file extension. ExUnit  can  generate standard format JUnit-style XML files  which can be  submitted  to Testfiesta or Testrail using Tacotruck CLI. You just need to check how to test using [`Exunit`](https://elixirschool.com/en/lessons/testing/basics) , and install Tacotruck CLI or use [Github action](https://github.com/testfiesta/tacotruck-action).  Check out simple ExUnit [example](https://github.com/testfiesta/tacotruck-examples/tree/main/demo_elixir_tf).

### Install Tacotruck CLI

{% code overflow="wrap" fullWidth="false" %}

```sh
$ npm install -g @testfiesta/tacotruck
```

{% endcode %}

### Submit test results

{% tabs %}
{% tab title="Testfiesta" %}

```sh
tacotruck testfiesta \
  run:submit \
  --token testfiesta_... \
  --handle orgHandle \
  --key projectKey \
  --name runName \
  --data results-path/*.xml
```

{% endtab %}
{% endtabs %}

### Support and Resources

* [TacoTruck Examples](https://github.com/testfiesta/tacotruck-examples)
* [ExUnit Docs](https://hexdocs.pm/ex_unit/ExUnit.html)
* [Tacotruck Issues](https://github.com/testfiesta/tacotruck/issues)
* [**CLI Reference**](https://docs.testfiesta.com/automation/tacotruck-cli)
* [Tacotruck Github Action](https://github.com/testfiesta/tacotruck-action)
