---
title: "Get-CatTestResultSummary"
description: "Get-CatTestResultSummary — the counts and rates of the last run."
url: "https://docs.justcat.it/reference/powershell-module/get-cattestresultsummary/"
---
# Get-CatTestResultSummary

## Synopsis

```powershell
Get-CatTestResultSummary
```

## Parameters

None (common parameters only).

## What it does

Writes the summary CAT kept from the last `Invoke-CatProject` / `Invoke-CatTest` in this session; before any run it returns nothing. This is how a script decides whether the run was good — neither `Invoke-*` cmdlet fails on failed tests.

## Output

One `TestExecutionSummary` object: `TotalCount`, `PassedCount`, `FailedCount`, `ErrorCount`, `InconclusiveCount`, `SkippedCount`, `PassRate`, `FailedRate`, `ErrorRate`, `InconclusiveRate` (percent), `StartedOn`, `FinishedOn`, `Duration`, `ExecutionGuid`, and `Results` — the same items `Get-CatTestResult` returns. `Inconclusive` is a test CAT could not bring to a verdict, not a failure.

## Errors

`There is no CAT session active…` when no session exists.

## Examples

```powershell
Invoke-CatProject -Path 'D:\Testing\DwhTests.cat.yaml'
$s = Get-CatTestResultSummary
"$($s.PassedCount)/$($s.TotalCount) passed, $($s.PassRate) %"
if ($s.FailedCount -gt 0 -or $s.ErrorCount -gt 0) { exit 1 }   # fail the pipeline
```

## Related

- [Introduction](https://docs.justcat.it/reference/powershell-module/introduction/ "Introduction") — session model, logging, errors, sign-in.
- [`Invoke-CatTest`](https://docs.justcat.it/reference/powershell-module/invoke-cattest/ "Invoke-CatTest") — returns this object directly.
- [`Get-CatTestResult`](https://docs.justcat.it/reference/powershell-module/get-cattestresult/ "Get-CatTestResult") · [`Show-CatTestResultSummary`](https://docs.justcat.it/reference/powershell-module/show-cattestresultsummary/ "Show-CatTestResultSummary").

