Initializing playground…
← Back to roadmap

testing utilities

assertSeriesEqual · assertFrameEqual · assertIndexEqual · mirrors pandas.testing

Import

TypeScript
Click ▶ Run to execute
Ctrl+Enter to run · Tab to indent

Passing example

TypeScript
Click ▶ Run to execute
Ctrl+Enter to run · Tab to indent

Failing example

TypeScript
Click ▶ Run to execute
Ctrl+Enter to run · Tab to indent

Float tolerance

TypeScript
Click ▶ Run to execute
Ctrl+Enter to run · Tab to indent

Passing example

TypeScript
Click ▶ Run to execute
Ctrl+Enter to run · Tab to indent

Ignore column order

TypeScript
Click ▶ Run to execute
Ctrl+Enter to run · Tab to indent

assertIndexEqual(left, right, options?)

Assert that two Index objects have identical labels.

TypeScript
Click ▶ Run to execute
Ctrl+Enter to run · Tab to indent

AssertionError

All failed assertions throw an AssertionError instance (extends Error). It can be caught explicitly or used with expect().toThrow(AssertionError) in bun:test.

TypeScript
Click ▶ Run to execute
Ctrl+Enter to run · Tab to indent