Project

guinea_pig

0.0
No commit activity in last 3 years
No release in over 3 years
Very simple ABTest functionality for Ruby, based in ActiveRecord and with Rails 3 generators
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

Runtime

~> 3.0
 Project Readme

GuineaPig

Very simple ABTest functionality for Ruby, based in ActiveRecord and with Rails 3 generators

Installation

Add this line to your application's Gemfile:

gem "guinea_pig"

Usage

Configure the experiments

# config/ab_experiments.yml
experiment_monkey:
  - "alternative_monkey_1"
  - "alternative_monkey_2"

experiment_elefant:
  - "alternative_elefant_1"
  - "alternative_elefant_2"
  - "alternative_elefant_3"

Create the table

rails generate guinea_pig:migration
rake db:migrate

Experiment!

LandingPage experiment

redirect_to GuineaPig.alternative(:experiment_monkey, user)

CSS experiment

<%= stylesheet_link_tag "/assets/css/#{GuineaPig.alternative(:experiment_monkey, user)}.css" %>

Convert!

if user.has_bought_something?
  GuineaPig.conversion(:experiment_monkey, user)
end

Sate of the art

Beta version but already used in production environments