Sha256: d0a2e30f0c0d17de009881a46afbfaf95ee9aa69b86d39c87957008d75a8dd80

Contents?: true

Size: 442 Bytes

Versions: 7

Compression:

Stored size: 442 Bytes

Contents

require 'wml_spec_helper'

describe Weskit::WML::Preprocessor do
  specify 'removes directives' do
    document = <<-DOC
      #define TEST
        a=b
      #enddef

      #undef TEST
      {TEST}

      #ifdef TEST
        {TEST}
      #else
        #ifdef BAR
          {BAR}
        #endif
      #endif
    DOC

    preprocessed = Weskit::WML::Preprocessor.new(document).remove_directives
    preprocessed.strip.should be_empty
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
weskit-0.3.6 spec/wml/preprocessor_spec.rb
weskit-0.3.5 spec/wml/preprocessor_spec.rb
weskit-0.3.4 spec/wml/preprocessor_spec.rb
weskit-0.3.3 spec/wml/preprocessor_spec.rb
weskit-0.3.2 spec/wml/preprocessor_spec.rb
weskit-0.3.1 spec/wml/preprocessor_spec.rb
weskit-0.3.0 spec/wml/preprocessor_spec.rb