Sha256: e5ba6930adb8da28102f8e034f14ab5d4731895e7d3ce35ea9f18a56bc1ff2d6
Contents?: true
Size: 1.12 KB
Versions: 10
Compression:
Stored size: 1.12 KB
Contents
# Copyright (C) 2008-2011 AMEE UK Ltd. - http://www.amee.com # Released as Open Source Software under the BSD 3-Clause license. See LICENSE.txt for details. require 'spec_helper.rb' require 'amee/rails' require 'active_record' describe AMEE::Rails do class AMEETest < ActiveRecord::Base include AMEE::Rails end it "should add the has_amee_profile method to a class which includes it" do AMEETest.respond_to?(:has_amee_profile).should be_true end describe "using has_amee_profile" do class HasProfileTest < AMEETest has_amee_profile end before(:each) do @test = disconnected HasProfileTest end it "should have an amee_connection function" do @test.klass.method_defined?(:amee_connection).should be_true end it "should have an amee_create function" do @test.klass.method_defined?(:amee_create).should be_true end it "should have an amee_save function" do @test.klass.method_defined?(:amee_save).should be_true end it "should have an amee_destroy function" do @test.klass.method_defined?(:amee_destroy).should be_true end end end
Version data entries
10 entries across 10 versions & 1 rubygems