Sha256: 2970666492add42b4232f45d4c12be8eb49c105df43d5d84a9968e9a5e92b022

Contents?: true

Size: 491 Bytes

Versions: 34

Compression:

Stored size: 491 Bytes

Contents

dir = File.expand_path(File.join(File.dirname(__FILE__), '..', 'lib'))
require File.join(dir, 'happymapper')

file_contents = File.read(dir + '/../spec/fixtures/commit.xml')

module GitHub
  class Commit
    include HappyMapper

    tag "commit"
    element :url, String
    element :tree, String
    element :message, String
    element :id, String
    element :'committed-date', Date
  end
end

commit = GitHub::Commit.parse(file_contents)
puts commit.committed_date, commit.url, commit.id

Version data entries

34 entries across 34 versions & 12 rubygems

Version Path
happymapper-0.5.0 examples/dashed_elements.rb
dam5s-happymapper-0.3.2 examples/dashed_elements.rb
jimmyz-happymapper-0.3.1 examples/dashed_elements.rb
jimmyz-happymapper-0.3.2 examples/dashed_elements.rb
jimmyz-happymapper-0.3.3 examples/dashed_elements.rb
jnunemaker-happymapper-0.2.1 examples/dashed_elements.rb
jnunemaker-happymapper-0.2.2 examples/dashed_elements.rb
jnunemaker-happymapper-0.2.3 examples/dashed_elements.rb
jnunemaker-happymapper-0.2.4 examples/dashed_elements.rb
jnunemaker-happymapper-0.2.5 examples/dashed_elements.rb
kdonovan-happymapper-0.3.4 examples/dashed_elements.rb
kdonovan-happymapper-0.3.5 examples/dashed_elements.rb
lightningdb-happymapper-0.3.0 examples/dashed_elements.rb
lightningdb-happymapper-0.3.1 examples/dashed_elements.rb
lightningdb-happymapper-0.3.2 examples/dashed_elements.rb
macasek-happymapper-0.2.5 examples/dashed_elements.rb
macasek-happymapper-0.2.6 examples/dashed_elements.rb
robmitch-happymapper-0.2.5 examples/dashed_elements.rb
happymapper-0.4.1 examples/dashed_elements.rb
happymapper-swanandp-0.4.0 examples/dashed_elements.rb