Sha256: 44f766b0f94f4e48828771e04edad79bcd2e5f4ac72580b08026c05d0ef03972
Contents?: true
Size: 584 Bytes
Versions: 2
Compression:
Stored size: 584 Bytes
Contents
require 'test_helper' module RetentionMagic class GraphsControllerTest < ActionController::TestCase setup do @routes = Engine.routes end test "index" do RetentionMagic.user_class = "User" RetentionMagic.activation_counter_columns = [ :posts_count ] RetentionMagic.retention_models = %w() User.create!(name: "John", created_at: Date.civil(2015, 10, 1), posts_count: 10) get :index assert_response :success assert_equal "Oct 2015", assigns(:first_cohort) assert_equal User, assigns(:user_class) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
retention_magic-0.1beta3 | test/controllers/retention_magic/graphs_controller_test.rb |
retention_magic-0.1beta2 | test/controllers/retention_magic/graphs_controller_test.rb |