Mercurial > kallithea
annotate rhodecode/tests/functional/test_feed.py @ 1974:edd3f202da4e beta
bumped mercurial to 2.1
author | Marcin Kuzminski <marcin@python-works.com> |
---|---|
date | Wed, 01 Feb 2012 22:50:10 +0200 |
parents | 113a8db22852 |
children | 7e5f8c12a3fc |
rev | line source |
---|---|
547
1e757ac98988
renamed project to rhodecode
Marcin Kuzminski <marcin@python-works.com>
parents:
473
diff
changeset
|
1 from rhodecode.tests import * |
205
66b20f525750
Added feed controllers, urls,and changed index page to use them.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
2 |
66b20f525750
Added feed controllers, urls,and changed index page to use them.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
3 class TestFeedController(TestController): |
66b20f525750
Added feed controllers, urls,and changed index page to use them.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff
changeset
|
4 |
459
7c978511c951
implemented basic (startup) nose test suite.
Marcin Kuzminski <marcin@python-works.com>
parents:
205
diff
changeset
|
5 def test_rss(self): |
473
6b934c9607e7
Improved testing scenarios. Made test env creator
Marcin Kuzminski <marcin@python-works.com>
parents:
459
diff
changeset
|
6 self.log_user() |
459
7c978511c951
implemented basic (startup) nose test suite.
Marcin Kuzminski <marcin@python-works.com>
parents:
205
diff
changeset
|
7 response = self.app.get(url(controller='feed', action='rss', |
688
8acbfa837180
Tests rewrite for 1.2 added some globals configs to make tests easier.
Marcin Kuzminski <marcin@python-works.com>
parents:
547
diff
changeset
|
8 repo_name=HG_REPO)) |
1064
113a8db22852
file tests updates + extended the feed tests
Marcin Kuzminski <marcin@python-works.com>
parents:
688
diff
changeset
|
9 |
113a8db22852
file tests updates + extended the feed tests
Marcin Kuzminski <marcin@python-works.com>
parents:
688
diff
changeset
|
10 |
113a8db22852
file tests updates + extended the feed tests
Marcin Kuzminski <marcin@python-works.com>
parents:
688
diff
changeset
|
11 |
113a8db22852
file tests updates + extended the feed tests
Marcin Kuzminski <marcin@python-works.com>
parents:
688
diff
changeset
|
12 assert response.content_type == "application/rss+xml" |
113a8db22852
file tests updates + extended the feed tests
Marcin Kuzminski <marcin@python-works.com>
parents:
688
diff
changeset
|
13 assert """<rss version="2.0">""" in response |
459
7c978511c951
implemented basic (startup) nose test suite.
Marcin Kuzminski <marcin@python-works.com>
parents:
205
diff
changeset
|
14 |
7c978511c951
implemented basic (startup) nose test suite.
Marcin Kuzminski <marcin@python-works.com>
parents:
205
diff
changeset
|
15 def test_atom(self): |
473
6b934c9607e7
Improved testing scenarios. Made test env creator
Marcin Kuzminski <marcin@python-works.com>
parents:
459
diff
changeset
|
16 self.log_user() |
459
7c978511c951
implemented basic (startup) nose test suite.
Marcin Kuzminski <marcin@python-works.com>
parents:
205
diff
changeset
|
17 response = self.app.get(url(controller='feed', action='atom', |
688
8acbfa837180
Tests rewrite for 1.2 added some globals configs to make tests easier.
Marcin Kuzminski <marcin@python-works.com>
parents:
547
diff
changeset
|
18 repo_name=HG_REPO)) |
1064
113a8db22852
file tests updates + extended the feed tests
Marcin Kuzminski <marcin@python-works.com>
parents:
688
diff
changeset
|
19 |
113a8db22852
file tests updates + extended the feed tests
Marcin Kuzminski <marcin@python-works.com>
parents:
688
diff
changeset
|
20 assert response.content_type == """application/atom+xml""" |
113a8db22852
file tests updates + extended the feed tests
Marcin Kuzminski <marcin@python-works.com>
parents:
688
diff
changeset
|
21 assert """<?xml version="1.0" encoding="utf-8"?>""" in response |
113a8db22852
file tests updates + extended the feed tests
Marcin Kuzminski <marcin@python-works.com>
parents:
688
diff
changeset
|
22 assert """<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-us">""" in response |