-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added test for index page, it just checks if it can find the a proper title for the page Signed-off-by: Vasudev Kamath <kamathvasudev@gmail.com>
- Loading branch information
Showing
2 changed files
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
# -*- coding: utf-8 -*- | ||
""" | ||
tests.frontend | ||
~~~~~~~~~~~~~~ | ||
frontend tests package | ||
""" | ||
|
||
from silpa.frontend import create_app | ||
from .. import SILPAAppTestCase, settings | ||
|
||
|
||
class SILPAFrontEndTestCase(SILPAAppTestCase): | ||
|
||
def _create_app(self): | ||
return create_app(settings) | ||
|
||
def setUp(self): | ||
super(SILPAFrontEndTestCase, self).setUp() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
# -*- coding: utf-8 -*- | ||
""" | ||
tests.frontend.mainpage_tests | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
main page frontend tests module | ||
""" | ||
|
||
from . import SILPAFrontEndTestCase | ||
|
||
|
||
class MainPageTestCase(SILPAFrontEndTestCase): | ||
|
||
def test_indexpage(self): | ||
r = self.get('/') | ||
self.assertIn('<title> SILPA - Indic Language Computing Platform ' + | ||
'</title>', self.assertOk(r).data) |