mbleigh / acts-as-taggable-on

A tagging plugin for Rails applications that allows for custom tagging along dynamic contexts.

This URL has Read+Write access

acts-as-taggable-on / spec / spec_helper.rb
100644 26 lines (19 sloc) 0.612 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
require File.dirname(__FILE__) + '/../../../../spec/spec_helper'
 
module Spec::Example::ExampleGroupMethods
  alias :context :describe
end
 
plugin_spec_dir = File.dirname(__FILE__)
ActiveRecord::Base.logger = Logger.new(plugin_spec_dir + "/debug.log")
 
load(File.dirname(__FILE__) + '/schema.rb')
 
class TaggableModel < ActiveRecord::Base
  acts_as_taggable_on :tags, :languages
  acts_as_taggable_on :skills
end
 
class InheritingTaggableModel < TaggableModel
end
 
class AlteredInheritingTaggableModel < TaggableModel
  acts_as_taggable_on :parts
end
 
class TaggableUser < ActiveRecord::Base
  acts_as_tagger
end