Socket
Book a DemoInstallSign in
Socket

minitest-snail

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

minitest-snail

0.0.1
bundlerRubygems
Version published
Maintainers
1
Created
Source

Minitest Snail

Prints a list of tests that take too long.

Installation

gem instal minitest-snail

Usage

Minitest Snail can be enabled from the command line using the max-duration parameter:

ruby test/example_test.rb --max-duration 2

This would print out a list of any tests taking longer than 2 seconds to run:

# Running:

....

Finished in 5.001143s

4 runs, 7 assertions, 0 failures, 0 errors, 0 skips

2 slow tests.
  0) ExampleTest#test_alpha: 2.30 s
  1) ExampleTest#test_beta: 2.11 s

If you don't run your tests directly, you can programmatically enable Minitest Snail:

Minitest::SnailReporter.enable!

You can also configure it using enable!:

Minitest::SnailReporter.enable! :max_duration => 2.5

If you are using Rails, your test/test_helper.rb file is good place to do this initialization.

Authors

Adam Sanderson (http://monkeyandcrow.com)

FAQs

Package last updated on 29 Mar 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.