
Security News
New Website “Is It Really FOSS?” Tracks Transparency in Open Source Distribution Models
A new site reviews software projects to reveal if they’re truly FOSS, making complex licensing and distribution models easy to understand.
Loupe is a test framework with built in parallel execution supporting Ractor or forked process modes.
Add the gem to the Gemfile
.
gem "loupe"
And then execute:
bundle install
Install bundler binstubs in your application.
bundle binstub loupe
Currently, Loupe only supports writing tests using the test methods syntax. Tests must inherit from Loupe::Test
, but do not need to explicitly require test_helper
, like the example below.
# frozen_string_literal: true
class MyTest < Loupe::Test
def before
@author = Author.create(name: "John")
@post = Post.create(author: @author)
end
def after
@author.destroy
@post.destroy
end
def test_post_is_linked_to_author
expect(@post.author.name).to_be_equal_to("John")
end
end
To run the test suite, invoke the executable using the binstub generated by bundler.
bin/loupe test/post_test.rb test/author_test.rb
Tests can run in parallel using Ractor or process mode. When using Ractors, the application's code must be Ractor compatible.
bin/loupe --ractor # [default] run tests using Ractor workers
bin/loupe --process # run tests using forked processes
bin/loupe --interactive # [default] use an interactive reporter to display test results
bin/loupe --plain # use a plain reporter to display test results
bin/loupe --color, --no-color # enable/disable output colors
bin/loupe --editor=EDITOR # which editor to use for opening files when using interactive mode. The default is the environment variable $EDITOR
To hook Loupe into Rake, use the provided rake task as in the example below.
# Rakefile
require "loupe/rake_task"
# Instantiate the task and append any desired CLI options
Loupe::RakeTask.new do |options|
options << "--plain"
end
# Optionally, set the default task to be test
task default: :test
Then run
bundle exec rake test
This project draws a lot of inspiration from other Ruby test frameworks, namely
Please refer to the guidelines in contributing.
FAQs
Unknown package
We found that loupe demonstrated a not healthy version release cadence and project activity because the last version was released 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
A new site reviews software projects to reveal if they’re truly FOSS, making complex licensing and distribution models easy to understand.
Security News
Astral unveils pyx, a Python-native package registry in beta, designed to speed installs, enhance security, and integrate deeply with uv.
Security News
The Latio podcast explores how static and runtime reachability help teams prioritize exploitable vulnerabilities and streamline AppSec workflows.