diff options
| author | Jurriaan Pruis <[email protected]> | 2012-03-27 13:55:42 +0200 |
|---|---|---|
| committer | Jurriaan Pruis <[email protected]> | 2012-03-27 13:55:42 +0200 |
| commit | 3867eb132f20c3258f007ca61a738e90a09087dc (patch) | |
| tree | e8d0b196badf01ceefe56aa02ac40ad82371afce /test/doc_props | |
| parent | 5afd30be1774fb5255dad2eb18c700d0d8f4a628 (diff) | |
| parent | be2d7bee9b9236fff4a378db8770c3ae793e8422 (diff) | |
| download | caxlsx-3867eb132f20c3258f007ca61a738e90a09087dc.tar.gz caxlsx-3867eb132f20c3258f007ca61a738e90a09087dc.zip | |
Merge github.com:randym/axlsx
Diffstat (limited to 'test/doc_props')
| -rw-r--r-- | test/doc_props/tc_app.rb | 7 | ||||
| -rw-r--r-- | test/doc_props/tc_core.rb | 9 |
2 files changed, 7 insertions, 9 deletions
diff --git a/test/doc_props/tc_app.rb b/test/doc_props/tc_app.rb index 546896a0..31c87c41 100644 --- a/test/doc_props/tc_app.rb +++ b/test/doc_props/tc_app.rb @@ -1,12 +1,11 @@ -require 'test/unit' -require 'axlsx.rb' +require 'tc_helper.rb' class TestApp < Test::Unit::TestCase - def setup + def setup end def teardown end - + def test_valid_document schema = Nokogiri::XML::Schema(File.open(Axlsx::APP_XSD)) doc = Nokogiri::XML(Axlsx::App.new.to_xml) diff --git a/test/doc_props/tc_core.rb b/test/doc_props/tc_core.rb index 5dd490a8..5e75d812 100644 --- a/test/doc_props/tc_core.rb +++ b/test/doc_props/tc_core.rb @@ -1,9 +1,8 @@ -require 'test/unit' -require 'axlsx.rb' +require 'tc_helper.rb' class TestCore < Test::Unit::TestCase - - def setup + + def setup @core = Axlsx::Core.new @doc = Nokogiri::XML(@core.to_xml) end @@ -21,7 +20,7 @@ class TestCore < Test::Unit::TestCase def test_populates_created assert_equal(@doc.xpath('//dcterms:created').text, Time.now.strftime('%Y-%m-%dT%H:%M:%S'), "dcterms:created incorrect") end - + def test_populates_default_name assert_equal(@doc.xpath('//dc:creator').text, "axlsx", "Default name not populated") end |
