Changeset 993

Show
Ignore:
Timestamp:
11/13/07 18:09:48 (1 year ago)
Author:
wyca..@gmail.com
Message:

Checks in :contents for match_tag

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/lib/merb/test/rspec.rb

    r804 r993  
    3131    def initialize(name, attrs) 
    3232      @name, @attrs = name, attrs 
     33      @content = @attrs.delete(:content) 
    3334    end 
    3435 
     
    4142        unless target.include?("#{attr}=\"#{val}\"") 
    4243          @errors << "Expected #{attr}=\"#{val}\", but was #{target}" 
     44        end 
     45      end 
     46      if @content 
     47        unless target.include?(">#{@content}<") 
     48          @errors << "Expected #{target} to include #{@content}" 
    4349        end 
    4450      end