Changesets can be listed by changeset number.
The Git repository is here.
- Revision:
- 15
- Log:
Attempt to update Typo to a Typo SVN HEAD release from around the
time the prototype installation was set up on the RISC OS Open Limited
web site. Timestamps place this at 04-Jul so a revision from 05-Jul or
earlier was pulled and copied over the 2.6.0 tarball stable code.
- Author:
- adh
- Date:
- Sat Jul 22 23:27:35 +0100 2006
- Size:
- 6598 Bytes
1 | require File.dirname(__FILE__) + '/../test_helper' |
2 | |
3 | class FlickrTest < Test::Unit::TestCase |
4 | |
5 | def setup |
6 | @flickr = FlickrAggregation.new("",false) |
7 | @flickr.send(:parse, fixture) |
8 | end |
9 | |
10 | # Replace this with your real tests. |
11 | def test_parser |
12 | assert_equal 6, @flickr.pics.size |
13 | end |
14 | |
15 | def test_random_chooser |
16 | assert_equal 4, @flickr.choose(4).size |
17 | end |
18 | |
19 | |
20 | def test_fields |
21 | assert_equal "xal's Photos", @flickr.title |
22 | assert_equal "http://www.flickr.com/photos/40235412@N00/", @flickr.link |
23 | assert_equal "A feed of xal's Photos", @flickr.description |
24 | end |
25 | |
26 | def test_image |
27 | assert_equal "p1010009", @flickr.pics[0].title |
28 | assert_equal "http://www.flickr.com/photos/40235412@N00/4903142/", @flickr.pics[0].link |
29 | assert_not_nil @flickr.pics[0].description |
30 | assert_equal Time.parse("Wed, 16 Feb 2005 07:15:48 -0800"), @flickr.pics[0].date |
31 | end |
32 | |
33 | def test_image_desc_parsers |
34 | assert_equal "http://photos3.flickr.com/4903142_ada4539ae8_m.jpg", @flickr.pics[0].image |
35 | assert_equal "http://photos3.flickr.com/4903142_ada4539ae8_t.jpg", @flickr.pics[0].thumb |
36 | end |
37 | |
38 | private |
39 | |
40 | def fixture |
41 | %{<?xml version="1.0" encoding="utf-8"?> |
42 | <rss version="2.0"> |
43 | <channel> |
44 | <title>xal's Photos</title> |
45 | <link>http://www.flickr.com/photos/40235412@N00/</link> |
46 | <description>A feed of xal's Photos</description> |
47 | <pubDate>Wed, 16 Feb 2005 07:15:48 -0800</pubDate> |
48 | <lastBuildDate>Wed, 16 Feb 2005 07:15:48 -0800</lastBuildDate> |
49 | <generator>http://www.flickr.com/</generator> |
50 | <image> |
51 | <url>http://www.flickr.com/images/buddyicon.jpg?40235412@N00</url> |
52 | <title>xals Photos</title> |
53 | <link>http://www.flickr.com/photos/40235412@N00/</link> |
54 | </image> |
55 | |
56 | <item> |
57 | <title>p1010009</title> |
58 | <link>http://www.flickr.com/photos/40235412@N00/4903142/</link> |
59 | <description><p><a href="http://www.flickr.com/people/40235412@N00/">xal</a> posted a photo:</p> |
60 | |
61 | <p><a href="http://www.flickr.com/photos/40235412@N00/4903142/" title="p1010009"><img src="http://photos3.flickr.com/4903142_ada4539ae8_m.jpg" width="240" height="180" alt="p1010009" style="border: 1px solid #000000;" /></a></p> |
62 | |
63 | </description> |
64 | <pubDate>Wed, 16 Feb 2005 07:15:48 -0800</pubDate> |
65 | <author>nobody@flickr.com (xal)</author> |
66 | <guid isPermaLink="false">tag:flickr.com,2004:/photo/4903142</guid> |
67 | </item> |
68 | <item> |
69 | <title>IMG_2472</title> |
70 | <link>http://www.flickr.com/photos/40235412@N00/4903134/</link> |
71 | <description><p><a href="http://www.flickr.com/people/40235412@N00/">xal</a> posted a photo:</p> |
72 | |
73 | <p><a href="http://www.flickr.com/photos/40235412@N00/4903134/" title="IMG_2472"><img src="http://photos5.flickr.com/4903134_c21069ee3d_m.jpg" width="240" height="180" alt="IMG_2472" style="border: 1px solid #000000;" /></a></p> |
74 | |
75 | </description> |
76 | <pubDate>Wed, 16 Feb 2005 07:15:28 -0800</pubDate> |
77 | <author>nobody@flickr.com (xal)</author> |
78 | <guid isPermaLink="false">tag:flickr.com,2004:/photo/4903134</guid> |
79 | </item> |
80 | <item> |
81 | <title>IMG_2463</title> |
82 | <link>http://www.flickr.com/photos/40235412@N00/4903116/</link> |
83 | <description><p><a href="http://www.flickr.com/people/40235412@N00/">xal</a> posted a photo:</p> |
84 | |
85 | <p><a href="http://www.flickr.com/photos/40235412@N00/4903116/" title="IMG_2463"><img src="http://photos4.flickr.com/4903116_27512793a4_m.jpg" width="240" height="180" alt="IMG_2463" style="border: 1px solid #000000;" /></a></p> |
86 | |
87 | </description> |
88 | <pubDate>Wed, 16 Feb 2005 07:14:57 -0800</pubDate> |
89 | <author>nobody@flickr.com (xal)</author> |
90 | <guid isPermaLink="false">tag:flickr.com,2004:/photo/4903116</guid> |
91 | </item> |
92 | <item> |
93 | <title>IMG_2367</title> |
94 | <link>http://www.flickr.com/photos/40235412@N00/4903079/</link> |
95 | <description><p><a href="http://www.flickr.com/people/40235412@N00/">xal</a> posted a photo:</p> |
96 | |
97 | <p><a href="http://www.flickr.com/photos/40235412@N00/4903079/" title="IMG_2367"><img src="http://photos4.flickr.com/4903079_7a2cbb125b_m.jpg" width="240" height="180" alt="IMG_2367" style="border: 1px solid #000000;" /></a></p> |
98 | |
99 | </description> |
100 | <pubDate>Wed, 16 Feb 2005 07:14:36 -0800</pubDate> |
101 | <author>nobody@flickr.com (xal)</author> |
102 | <guid isPermaLink="false">tag:flickr.com,2004:/photo/4903079</guid> |
103 | </item> |
104 | <item> |
105 | <title>IMG_2365</title> |
106 | <link>http://www.flickr.com/photos/40235412@N00/4903059/</link> |
107 | <description><p><a href="http://www.flickr.com/people/40235412@N00/">xal</a> posted a photo:</p> |
108 | |
109 | <p><a href="http://www.flickr.com/photos/40235412@N00/4903059/" title="IMG_2365"><img src="http://photos5.flickr.com/4903059_72a2d9ca1e_m.jpg" width="240" height="180" alt="IMG_2365" style="border: 1px solid #000000;" /></a></p> |
110 | |
111 | </description> |
112 | <pubDate>Wed, 16 Feb 2005 07:14:17 -0800</pubDate> |
113 | <author>nobody@flickr.com (xal)</author> |
114 | <guid isPermaLink="false">tag:flickr.com,2004:/photo/4903059</guid> |
115 | </item> |
116 | <item> |
117 | <title>IMG_2201</title> |
118 | <link>http://www.flickr.com/photos/40235412@N00/4903030/</link> |
119 | <description><p><a href="http://www.flickr.com/people/40235412@N00/">xal</a> posted a photo:</p> |
120 | |
121 | <p><a href="http://www.flickr.com/photos/40235412@N00/4903030/" title="IMG_2201"><img src="http://photos5.flickr.com/4903030_9a7fcb492e_m.jpg" width="240" height="180" alt="IMG_2201" style="border: 1px solid #000000;" /></a></p> |
122 | |
123 | </description> |
124 | <pubDate>Wed, 16 Feb 2005 07:13:59 -0800</pubDate> |
125 | <author>nobody@flickr.com (xal)</author> |
126 | <guid isPermaLink="false">tag:flickr.com,2004:/photo/4903030</guid> |
127 | </item> |
128 | |
129 | </channel> |
130 | </rss> |
131 | } |
132 | end |
133 | |
134 | end |