mingle_events 0.1.8 → 0.1.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/mingle_events/xml.rb +1 -1
- data/test/mingle_events/feed/changes_test.rb +31 -0
- data/test/mingle_events/xml_test.rb +1 -0
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 4781909d8e51e73f1b77efcbafb9b94e5c0bf241
|
|
4
|
+
data.tar.gz: 7db2de0be1b4383a6b9e90035d549d4d19f52e08
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 604f1d166e69cc11fbe15e4f7959321ee707829a3541d566fb38967d90b79021acf5e2bfcf830fb314a785b29b3e585b50d30211c3fa303a2d056924d5343c93
|
|
7
|
+
data.tar.gz: ea73fa6942fbdcfd8845cd8c24ae347bb17a6e03c5525224f90ed6c6afe9114c903f91e5965f4f1ff1a4835d965cab708eb516e74ba93c87348a544d8a6028f2
|
data/lib/mingle_events/xml.rb
CHANGED
|
@@ -319,6 +319,37 @@ module MingleEvents
|
|
|
319
319
|
assert_equal(nil, change[:old_value])
|
|
320
320
|
end
|
|
321
321
|
|
|
322
|
+
|
|
323
|
+
def test_parse_card_creation_changes
|
|
324
|
+
element_xml_text = %{
|
|
325
|
+
<entry xmlns="http://www.w3.org/2005/Atom">
|
|
326
|
+
<content type="application/vnd.mingle+xml">
|
|
327
|
+
<changes xmlns="http://www.thoughtworks-studios.com/ns/mingle">
|
|
328
|
+
<change type="card-creation"/>
|
|
329
|
+
</changes>
|
|
330
|
+
</content>
|
|
331
|
+
</entry>}
|
|
332
|
+
entry = Entry.from_snippet(element_xml_text)
|
|
333
|
+
|
|
334
|
+
change = entry.changes.first
|
|
335
|
+
assert_equal(Category::CARD_CREATION, change[:type])
|
|
336
|
+
end
|
|
337
|
+
|
|
338
|
+
def test_parse_card_description_changes
|
|
339
|
+
element_xml_text = %{
|
|
340
|
+
<entry xmlns="http://www.w3.org/2005/Atom">
|
|
341
|
+
<content type="application/vnd.mingle+xml">
|
|
342
|
+
<changes xmlns="http://www.thoughtworks-studios.com/ns/mingle">
|
|
343
|
+
<change type="description-change">
|
|
344
|
+
</change>
|
|
345
|
+
</changes>
|
|
346
|
+
</content>
|
|
347
|
+
</entry>}
|
|
348
|
+
entry = Entry.from_snippet(element_xml_text)
|
|
349
|
+
|
|
350
|
+
change = entry.changes.first
|
|
351
|
+
assert_equal(Category::DESCRIPTION_CHANGE, change[:type])
|
|
352
|
+
end
|
|
322
353
|
end
|
|
323
354
|
|
|
324
355
|
end
|
|
@@ -42,6 +42,7 @@ module MingleEvents
|
|
|
42
42
|
assert_equal({:a => 's'}, Xml.parse('<a x="y">s</a>').select('a').to_hash)
|
|
43
43
|
assert_equal({:a => "\u00A0"}, Xml.parse('<a> </a>').select('a').to_hash)
|
|
44
44
|
assert_equal({:a => { :x => 'y'}}, Xml.parse('<a x="y"></a>').select('a').to_hash)
|
|
45
|
+
assert_equal({:a => { :x => 'y'}}, Xml.parse("<a x=\"y\">\n </a>").select('a').to_hash)
|
|
45
46
|
|
|
46
47
|
end
|
|
47
48
|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: mingle_events
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.9
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- David Rice
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2015-02-08 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: nokogiri
|