
Security News
ECMAScript 2025 Finalized with Iterator Helpers, Set Methods, RegExp.escape, and More
ECMAScript 2025 introduces Iterator Helpers, Set methods, JSON modules, and more in its latest spec update approved by Ecma in June 2025.
A delightful nyan-cat inspired pytest plugin that displays test results with a colorful nyan cat animation and rainbow trail.
========================================================================āāāāāāāāāāāāāāāāāāāā®
======================================================================āāāāāāā« ā„ * ā„ * ā„ *ā ā® ā®
====================================================================āāāāāāā* ā„ * ā„ * ā„ ā(^į“„^)
====================================================================āāāāā-ā« ā„ * ā„ * ā„ *ā£āÆ
======================================================================āāāāāāā°āāāāāāāāāāāāāÆ
========================================================================āāāāāā ā°ā ā°ā ā°ā ā°ā
Tests: 42/50 ā
38 ā 3 āļø 1
Nyan cat flying through your test results with a beautiful rainbow trail!
pip install nyan-pytest
For development:
git clone https://github.com/your-repo/nyan-pytest
cd nyan-pytest
make setup
Run pytest with nyan cat alongside standard output:
pytest --nyan
Use only nyan cat (cleaner output):
pytest --nyan-only
Want to see nyan cat in action? Try the simulation mode:
# Quick demo with 20 simulated tests
pytest --nyan-sim 20
# Epic demo with 100 tests
pytest --nyan-sim 100
# Fast animation demo
pytest --nyan-sim 30 --nyan-speed 2
# Moderate speed
pytest --nyan-sim 30 --nyan-speed 15
# Slow, relaxing animation
pytest --nyan-sim 30 --nyan-speed 50
This project includes a comprehensive Makefile for development:
# Show all available commands
make help
# Run tests with nyan cat
make test-nyan
# Quick demo
make demo
# Epic party mode! š
make party
# Performance benchmarking
make benchmark
# Development setup
make setup
Option | Description |
---|---|
--nyan | Enable nyan cat reporter alongside default pytest output |
--nyan-only | Use only nyan cat reporter (no standard pytest output) |
--nyan-sim N | Simulate N tests to demo the animation |
--nyan-speed N | Animation speed (1=fastest, 6=default, 100=slowest) |
Speed Range | Best For | Description |
---|---|---|
1-3 | Fast unit tests | Quick visual feedback, minimal distraction |
4-8 | Regular development | Good balance of visibility and speed (default: 6) |
10-25 | Watching tests run | Comfortable viewing during test execution |
30-60 | Relaxed development | Slow, enjoyable animation for longer test suites |
70-100 | Demos & presentations | Very slow, perfect for showing off to colleagues! |
When running tests, you'll see:
āāāāāāāāāāāāāāāāāāāā®
āāāāāāā« ā„ * ā„ * ā„ *ā ā® ā®
āāāāāāā* ā„ * ā„ * ā„ ā(^į“„^)
āāāāā-ā« ā„ * ā„ * ā„ *ā£āÆ
āāāāāāā°āāāāāāāāāāāāāÆ
āāāāāā ā°ā ā°ā ā°ā ā°ā
Tests: 15/20 ā
12 ā 2 āļø 1
ā
characters) grows as tests complete# Clone and setup
git clone <repo-url>
cd nyan-pytest
make setup
# Run tests
make test-nyan
# Check code quality
make lint
# Try the demo
make demo
Command | Description |
---|---|
make setup | Install dev dependencies |
make test-nyan | Run tests with nyan output |
make demo | Demo with 20 simulated tests |
make performance | Run performance benchmarks |
make lint | Check code quality |
make format | Format code |
make build | Build package |
make clean | Clean build artifacts |
# Standard pytest with nyan enhancement
pytest tests/ --nyan -v
# Clean nyan-only output
pytest tests/ --nyan-only
# Verbose mode with test details
pytest tests/ --nyan -v -s
# Benchmark nyan vs standard reporter
make benchmark
# Time the plugin performance
make performance
# Quick 10-test demo
make demo-fast
# Standard 20-test demo
make demo
# Longer 50-test demo
make demo-slow
# Epic 100-test party! š
make party
TL;DR: The delight factor far outweighs the modest performance cost!
Nyan cat adds visual joy to your testing workflow with minimal impact on development productivity. Benchmarks show the animation overhead is essentially constant (~2.3 seconds) regardless of test count:
Test Count | Standard | Nyan Cat | Overhead | % Slower |
---|---|---|---|---|
10 tests | 0.18s | 2.41s | +2.23s | +1225% |
100 tests | 1.26s | 3.52s | +2.27s | +181% |
1000 tests | 11.97s | 14.31s | +2.33s | +20% |
šÆ Animation overhead is constant - The ~2.3 second cost doesn't scale with test count
š Scales beautifully - Larger test suites see proportionally less impact
ā” Negligible in practice - 2-3 seconds is nothing compared to typical development workflows
ā Perfect for:
ā Why the overhead is worth it:
# Run the performance comparison tool
make performance TESTS=100
# Test different scales
make performance TESTS=10 # Small suite
make performance TESTS=1000 # Large suite
# Compare with your actual test suite
time pytest your_tests/ --nyan-only
time pytest your_tests/ -q # Standard output
Bottom line: Unless you're running thousands of ultra-fast unit tests in tight development loops, nyan cat's constant ~2.3s overhead becomes increasingly negligible as your test suite grows. The joy, motivation, and visual feedback it provides make it a net positive for virtually any development workflow. Adoption is strongly encouraged! š
git checkout -b feature-name
make full-check
MIT License - see LICENSE file for details.
Inspired by the original Nyan Cat. This one's for the ktties.
FAQs
A nyan-cat inspired test reporter for pytest
We found that nyan-pytest demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago.Ā It has 1 open source maintainer collaborating on the project.
Did you know?
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.
Security News
ECMAScript 2025 introduces Iterator Helpers, Set methods, JSON modules, and more in its latest spec update approved by Ecma in June 2025.
Security News
A new Node.js homepage button linking to paid support for EOL versions has sparked a heated discussion among contributors and the wider community.
Research
North Korean threat actors linked to the Contagious Interview campaign return with 35 new malicious npm packages using a stealthy multi-stage malware loader.