Sha256: ea62343ddcb2c5aa55c9640e1188aaed0a4b0f243ec7d44f41236cd521a524db

Contents?: true

Size: 824 Bytes

Versions: 36

Compression:

Stored size: 824 Bytes

Contents

require File.dirname(__FILE__) + '/test_helper'
require 'mofo/hcard'

context "Multiple attributes within a container" do
  setup do
    $hcards    ||= HCard.find(:all => fixture(:hresume))
    $included  ||= $hcards.first
    $including ||= $hcards[1]
  end

  specify "should be referenceable by a microformat using the include pattern" do
    %w(fn n).each do |att|
      $including.send(att).should.equal $included.send(att)
    end
  end
end

context "A single attribute" do
  setup do
    $horsed ||= HCard.find(:first => fixture(:include_pattern_single_attribute))
  end

  specify "should be referenceable by a microformat using the include pattern" do
    $horsed.logo.should.not.be.nil
    $horsed.logo.should.equal Hpricot(open(fixture(:include_pattern_single_attribute))).at("#logo").attributes['src']
  end
end

Version data entries

36 entries across 23 versions & 3 rubygems

Version Path
calagator-1.0.0 vendor/gems/mofo-0.2.8/test/include_pattern_test.rb
grokus-1.0.0.9 vendor/gems/mofo-0.2.8/test/include_pattern_test.rb
grokus-1.0.0.8 vendor/gems/mofo-0.2.8/test/include_pattern_test.rb
grokus-1.0.0.7 vendor/gems/mofo-0.2.8/test/include_pattern_test.rb
grokus-1.0.0.6 vendor/gems/mofo-0.2.8/test/include_pattern_test.rb
grokus-1.0.0.5 vendor/gems/mofo-0.2.8/test/include_pattern_test.rb
grokus-1.0.0.3 vendor/gems/mofo-0.2.8/test/include_pattern_test.rb
grokus-1.0.0.2 vendor/gems/mofo-0.2.8/test/include_pattern_test.rb
grokus-1.0.0.1 vendor/gems/mofo-0.2.8/test/include_pattern_test.rb
calagator-1.0.0.rc3 vendor/gems/mofo-0.2.8/test/include_pattern_test.rb
mofo-0.2.14 ./test/include_pattern_test.rb
mofo-0.2.15 ./test/include_pattern_test.rb
mofo-0.2.15 test/include_pattern_test.rb
mofo-0.2.16 ./test/include_pattern_test.rb
mofo-0.2.16 test/include_pattern_test.rb
mofo-0.2.3 ./test/include_pattern_test.rb
mofo-0.2.3 test/include_pattern_test.rb
mofo-0.2.10 ./test/include_pattern_test.rb
mofo-0.2.4 test/include_pattern_test.rb
mofo-0.2.5 ./test/include_pattern_test.rb