Skip to content

Commit a21d665

Browse files
committed
add new webmention.rocks based tests and helper tool
1 parent 34014d6 commit a21d665

31 files changed

+4289
-1300
lines changed

MANIFEST.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ include *.py
77
recursive-include docs *.md
88
recursive-include tests *.py
99
recursive-include tests *.html
10+
recursive-include tests *.json
1011
recursive-include examples *.py
1112
prune .DS_Store
1213
prune .git

tests/data/webmention_rocks_test_1.html

Lines changed: 473 additions & 160 deletions
Large diffs are not rendered by default.
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
{
2-
"Content-Length": "5767",
2+
"Content-Length": "33731",
33
"X-Powered-By": "PHP/5.6.18-1+deb.sury.org~trusty+1",
44
"Server": "nginx/1.9.10",
55
"Connection": "keep-alive",
66
"Link": "</test/1/webmention>; rel=webmention",
7-
"Date": "Mon, 11 Apr 2016 04:17:20 GMT",
7+
"Date": "Thu, 14 Apr 2016 19:14:19 GMT",
88
"Content-Type": "text/html; charset=UTF-8"
99
}
Lines changed: 202 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,202 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="utf-8" />
5+
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
6+
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
7+
8+
<title>Webmention Rocks!</title>
9+
<link href="/assets/semantic.min.css" rel="stylesheet">
10+
<link href="/assets/style.css" rel="stylesheet">
11+
<link href="/assets/test.css" rel="stylesheet">
12+
13+
<script src="/assets/jquery-1.11.3.min.js"></script>
14+
<script src="/assets/semantic.min.js"></script>
15+
16+
17+
</head>
18+
<body>
19+
20+
21+
<div class="post-container h-entry">
22+
<div class="post-main has-responses">
23+
<div class="left p-author h-card">
24+
<a href="/">
25+
<img src="/assets/webmention-rocks-icon.png" width="80" class="u-photo" alt="Webmention Rocks!">
26+
</a>
27+
</div>
28+
<div class="right">
29+
<h1 class="p-name"><a href="/test/10">Test #10</a></h1>
30+
<div class="e-content">This post has an HTTP Link header with multiple rel values.</div>
31+
<div class="meta">
32+
<a href="/test/10" class="u-url">
33+
<time class="dt-published" datetime="2016-04-14T09:14:23-07:00">
34+
Thursday April 14, 2016 9:14am -07:00 </time>
35+
</a>
36+
</div>
37+
</div>
38+
</div>
39+
<div class="post-responses">
40+
<div id="debug"></div>
41+
42+
<div class="responses-row reacji empty">
43+
<div style="padding: 12px 12px 3px 12px;">
44+
<h3 style="margin: 0;">Reacji</h3>
45+
<p class="help-text">The emoji below show <a href="http://indiewebcamp.com/reacji">Reacji</a> responses, created by people posting a comment linking to this post with an <code><a href="http://indiewebcamp.com/in-reply-to">in-reply-to</a></code> property, whose text is a single emoji character.</p>
46+
</div>
47+
<ul class="reacji stream reacji">
48+
</ul>
49+
<div style="clear:both;"></div>
50+
</div>
51+
52+
<div class="responses-row like ">
53+
<div style="padding: 12px 12px 3px 12px;">
54+
<h3 style="margin: 0;">Likes</h3>
55+
<p class="help-text">
56+
The profile icons below are the <a href="http://indiewebcamp.com/authorship">author</a> photos from people who have posted a "like" post on their site, where their post links to this post with the <code><a href="http://indiewebcamp.com/like-of">like-of</a></code> property.</p> </p>
57+
</div>
58+
<div class="facepile-type-icon"><i class="ui star icon"></i></div>
59+
<ul class="facepile stream like">
60+
<li class="p-like h-cite" data-response-id="355bcfffe51e4aa0f49f78e847b83315">
61+
<a href="https://bear.im/bearlog/2016/101/testing-webmention-rocks-likes.html" class="u-url" rel="nofollow">
62+
<span class="p-author h-card author">
63+
<img class="u-photo" src="/image?url=https%3A%2F%2Fbear.im%2Fimages%2Fbear_145x145.jpg&sig=71d68c1e03e6214a359ca7a04ab2c0f67fafcaabe9e342788047768500a04b49"
64+
width="48" alt="Mike Taylor">
65+
</span>
66+
</a>
67+
</li>
68+
</ul>
69+
<div style="clear:both;"></div>
70+
</div>
71+
<div class="responses-row repost empty">
72+
<div style="padding: 12px 12px 3px 12px;">
73+
<h3 style="margin: 0;">Reposts</h3>
74+
<p class="help-text">
75+
The profile icons below are the <a href="http://indiewebcamp.com/authorship">author</a> photos from people who have posted a "repost" of this post on their site, where their post links to this post with the <code><a href="http://indiewebcamp.com/repost-of">repost-of</a></code> property.</p> </p>
76+
</div>
77+
<div class="facepile-type-icon"><i class="ui retweet icon"></i></div>
78+
<ul class="facepile stream repost">
79+
</ul>
80+
<div style="clear:both;"></div>
81+
</div>
82+
<div class="responses-row bookmark empty">
83+
<div style="padding: 12px 12px 3px 12px;">
84+
<h3 style="margin: 0;">Bookmarks</h3>
85+
<p class="help-text">
86+
The profile icons below are the <a href="http://indiewebcamp.com/authorship">author</a> photos from people who have posted a bookmark of this post on their site, where their post links to this post with the <code><a href="http://indiewebcamp.com/bookmark-of">bookmark-of</a></code> property.</p> </p>
87+
</div>
88+
<div class="facepile-type-icon"><i class="ui bookmark icon"></i></div>
89+
<ul class="facepile stream bookmark">
90+
</ul>
91+
<div style="clear:both;"></div>
92+
</div>
93+
94+
<div class="responses-row reply empty">
95+
<div style="padding: 12px 12px 3px 12px;">
96+
<h3 style="margin: 0;">Comments</h3>
97+
<p class="help-text">The comments below are replies to this post, and marked up their link to the post with the <code><a href="http://indiewebcamp.com/in-reply-to">in-reply-to</a></code> property.</p>
98+
</div>
99+
<ul class="comments stream reply">
100+
</ul>
101+
</div>
102+
103+
<div class="responses-row mention ">
104+
<div style="padding: 12px 12px 3px 12px;">
105+
<h3 style="margin: 0;">Mentions</h3>
106+
<p class="help-text">The mentions below linked to this post, but did not include this post's URL as an <code><a href="http://indiewebcamp.com/in-reply-to">in-reply-to</a></code> property.</p>
107+
</div>
108+
<ul class="comments stream mention">
109+
<li class="p-mention h-cite" data-response-id="471adf4d4cb4b18849c1bc1915556817">
110+
<div class="comment">
111+
<div class="p-author h-card author">
112+
<img class="u-photo" src="/image?url=http%3A%2F%2Fmention-tech.appspot.com%2Fstatic%2Flogo.jpg&sig=9294659a9f4796e6d8a9c421895e193e17d41c997628ce882b1c003974c310c9" width="48">
113+
<a class="p-name u-url" href="http://mention-tech.appspot.com/" rel="nofollow">
114+
http://mention-tech.appspot.com/static/logo.jpgmention.tech </a>
115+
<a class="author-url" href="http://mention-tech.appspot.com/" rel="nofollow">
116+
mention-tech.appspot.com </a>
117+
</div>
118+
<div class="comment-content">
119+
<a href="http://mention-tech.appspot.com/testing.html#" rel="nofollow">
120+
<h3 class="p-name">Test page for pinging webmention.rocks from</h3>
121+
</a>
122+
</div>
123+
<div class="meta">
124+
<a class="u-url" href="http://mention-tech.appspot.com/testing.html#" rel="nofollow">
125+
<time class="dt-published" datetime="2016-04-11T00:00:00+00:00">
126+
Monday, April 11, 2016 12:00am +00:00 </time>
127+
</a>
128+
</div>
129+
</div>
130+
</li>
131+
<li class="p-mention h-cite" data-response-id="148fcc96b96d69d60ef998e30bbd6dea">
132+
<div class="comment">
133+
<div class="p-author h-card author">
134+
<img class="u-photo" src="/image?url=https%3A%2F%2Faaronparecki.com%2Fimages%2Faaronpk-256.jpg&sig=3c1599f61a4ad25d74ff009b67b2ff47d508b269a327ea1a40b07840280e6877" width="48">
135+
<a class="p-name u-url" href="https://aaronparecki.com/" rel="nofollow">
136+
Aaron Parecki </a>
137+
<a class="author-url" href="https://aaronparecki.com/" rel="nofollow">
138+
aaronparecki.com </a>
139+
</div>
140+
<div class="comment-content">
141+
<div class="e-content "><p>Here is my test post for <a href="https://webmention.rocks" rel="nofollow">webmention.rocks</a>! Posted using <a href="http://p3k.io/" rel="nofollow">p3k</a>, Webmentions sent by <a href="https://telegraph.p3k.io/" rel="nofollow">Telegraph</a> using the <a href="https://github.com/indieweb/mention-client-php" rel="nofollow">mention-client-php</a> library.</p>
142+
143+
<p><a href="https://webmention.rocks/test/1" rel="nofollow">Test 1</a>,
144+
<a href="https://webmention.rocks/test/2" rel="nofollow">Test 2</a>,
145+
<a href="https://webmention.rocks/test/3" rel="nofollow">Test 3</a>,
146+
<a href="https://webmention.rocks/test/4" rel="nofollow">Test 4</a>,
147+
<a href="https://webmention.rocks/test/5" rel="nofollow">Test 5</a>,
148+
<a href="https://webmention.rocks/test/6" rel="nofollow">Test 6</a>,
149+
<a href="https://webmention.rocks/test/7" rel="nofollow">Test 7</a>,
150+
<a href="https://webmention.rocks/test/8" rel="nofollow">Test 8</a>,
151+
<a href="https://webmention.rocks/test/9" rel="nofollow">Test 9</a>,
152+
<a href="https://webmention.rocks/test/10" rel="nofollow">Test 10</a>,
153+
<a href="https://webmention.rocks/test/11" rel="nofollow">Test 11</a>,
154+
<a href="https://webmention.rocks/test/12" rel="nofollow">Test 12</a>,
155+
<a href="https://webmention.rocks/test/13" rel="nofollow">Test 13</a>,
156+
<a href="https://webmention.rocks/test/14" rel="nofollow">Test 14</a>
157+
</p></div>
158+
</div>
159+
<div class="meta">
160+
<a class="u-url" href="https://aaronparecki.com/2016/04/14/20/webmention-rocks" rel="nofollow">
161+
<time class="dt-published" datetime="2016-04-14T18:12:37+02:00">
162+
Thursday, April 14, 2016 6:12pm +02:00 </time>
163+
</a>
164+
</div>
165+
</div>
166+
</li>
167+
<li class="p-mention h-cite" data-response-id="c227b7c381837a779c819a51af8d4e24">
168+
<div class="comment">
169+
<div class="p-author h-card author">
170+
<img class="u-photo" src="/image?url=https%3A%2F%2Fbear.im%2Fimages%2Fbear_145x145.jpg&sig=71d68c1e03e6214a359ca7a04ab2c0f67fafcaabe9e342788047768500a04b49" width="48">
171+
<a class="p-name u-url" href="https://bear.im/" rel="nofollow">
172+
Mike Taylor </a>
173+
<a class="author-url" href="https://bear.im/" rel="nofollow">
174+
bear.im </a>
175+
</div>
176+
<div class="comment-content">
177+
<a href="https://bear.im/bearlog/2016/101/testing-webmention-rocks.html" rel="nofollow">
178+
<h3 class="p-name">Testing Webmention.rocks</h3>
179+
</a>
180+
</div>
181+
<div class="meta">
182+
<a class="u-url" href="https://bear.im/bearlog/2016/101/testing-webmention-rocks.html" rel="nofollow">
183+
<time class="dt-published" datetime="2016-04-10T22:48:34+00:00">
184+
Sunday, April 10, 2016 10:48pm +00:00 </time>
185+
</a>
186+
</div>
187+
</div>
188+
</li>
189+
</ul>
190+
</div>
191+
192+
</div>
193+
<div class="post-footer">
194+
<p>Responses are stored for 48 hours and may be deleted after that time.</p>
195+
</div>
196+
</div>
197+
198+
<div id="test-num" data-num="10"></div>
199+
<script src="/assets/streaming.js"></script>
200+
201+
</body>
202+
</html>
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
{
2+
"Content-Length": "10965",
3+
"X-Powered-By": "PHP/5.6.18-1+deb.sury.org~trusty+1",
4+
"Server": "nginx/1.9.10",
5+
"Connection": "keep-alive",
6+
"Link": "<https://webmention.rocks/test/10/webmention>; rel=\"webmention somethingelse\"",
7+
"Date": "Thu, 14 Apr 2016 19:14:23 GMT",
8+
"Content-Type": "text/html; charset=UTF-8"
9+
}

0 commit comments

Comments
 (0)