---
title: expect.planner() function
description: expect.planner() will cause the present testcase to expect the given planner rules will be invoked exactly as many times as the number given.
url: https://docs.influxdata.com/flux/v0/stdlib/testing/expect/planner/
estimated_tokens: 303
product: Flux
version: v0
---

# expect.planner() function

-   Flux 0.14.0+
-   View InfluxDB support

`expect.planner()` will cause the present testcase to expect the given planner rules will be invoked exactly as many times as the number given.

The key is the name of the planner rule.

##### Function type signature

```js
(rules: [string:int]) => {}
```

For more information, see [Function type signatures](/flux/v0/function-type-signatures/).

## Parameters

### rules

(Required) Mapping of rules names to expected counts.
