File tree 7 files changed +121
-1
lines changed
7 files changed +121
-1
lines changed Original file line number Diff line number Diff line change
1
+ [run]
2
+ branch = True
3
+ source = aldryn_bootstrap3
4
+ omit =
5
+ migrations/*
6
+ tests/*
7
+
8
+ [report]
9
+ exclude_lines =
10
+ pragma: no cover
11
+ def __repr__
12
+ if self.debug:
13
+ if settings.DEBUG
14
+ raise AssertionError
15
+ raise NotImplementedError
16
+ if 0:
17
+ if __name__ == .__main__.:
18
+ ignore_errors = True
Original file line number Diff line number Diff line change 1
1
language : python
2
2
3
- script : true
3
+ sudo : false
4
+
5
+ env :
6
+ - TOX_ENV=flake8
7
+ - TOX_ENV=py27-latest
8
+ - TOX_ENV=py34-latest
9
+ # Django 1.8
10
+ - TOX_ENV=py27-dj18-cms34
11
+ - TOX_ENV=py27-dj18-cms33
12
+ - TOX_ENV=py34-dj18-cms34
13
+ - TOX_ENV=py34-dj18-cms33
14
+ # Django 1.9
15
+ - TOX_ENV=py27-dj19-cms34
16
+ - TOX_ENV=py27-dj19-cms33
17
+ - TOX_ENV=py34-dj19-cms34
18
+ - TOX_ENV=py34-dj19-cms33
19
+
20
+ install :
21
+ - pip install tox coverage
22
+
23
+ script :
24
+ - tox -e $TOX_ENV
25
+
26
+ after_success :
27
+ - bash <(curl -s https://codecov.io/bash)
Original file line number Diff line number Diff line change
1
+ # -*- coding: utf-8 -*-
Original file line number Diff line number Diff line change
1
+ # requirements from setup.py
2
+ Django < 1.10
3
+ djangocms-text-ckeditor
4
+ # other requirements
5
+ djangocms-helper >= 0.9.2 ,< 0.10
6
+ tox
7
+ coverage
Original file line number Diff line number Diff line change
1
+ #!/usr/bin/env python
2
+ # -*- coding: utf-8 -*-
3
+
4
+ HELPER_SETTINGS = {
5
+ 'INSTALLED_APPS' : [
6
+ 'easy_thumbnails' ,
7
+ 'filer' ,
8
+ 'mptt' ,
9
+ 'djangocms_text_ckeditor' ,
10
+ ],
11
+ 'ALLOWED_HOSTS' : ['localhost' ],
12
+ 'CMS_LANGUAGES' : {
13
+ 1 : [{
14
+ 'code' : 'en' ,
15
+ 'name' : 'English' ,
16
+ }]
17
+ },
18
+ 'LANGUAGE_CODE' : 'en' ,
19
+ }
20
+
21
+ def run ():
22
+ from djangocms_helper import runner
23
+ runner .cms ('aldryn_bootstrap3' )
24
+
25
+ if __name__ == '__main__' :
26
+ run ()
Original file line number Diff line number Diff line change
1
+ # -*- coding: utf-8 -*-
2
+ from django .test import TestCase
3
+
4
+ from aldryn_bootstrap3 .models import Boostrap3ButtonPlugin
5
+
6
+
7
+ class Boostrap3ButtonPluginTestCase (TestCase ):
8
+
9
+ def setUp (self ):
10
+ Boostrap3ButtonPlugin .objects .create (
11
+ label = 'test' ,
12
+ )
13
+
14
+ def test_bootstrap3_button_instance (self ):
15
+ """Button instance has been created"""
16
+ button = Boostrap3ButtonPlugin .objects .get (label = 'test' )
17
+ self .assertEqual (button .label , 'test' )
Original file line number Diff line number Diff line change
1
+ [tox]
2
+ envlist =
3
+ flake8
4
+ py{34,27}-latest
5
+ py{34,27}-dj18-cms{34,33}
6
+ py{34,27}-dj19-cms{34,33}
7
+
8
+ skip_missing_interpreters =True
9
+
10
+
11
+ [testenv]
12
+ deps =
13
+ -r{toxinidir}/tests/requirements.txt
14
+ dj18: Django>=1.8,<1.9
15
+ dj19: Django>=1.9,<1.10
16
+ latest: django-cms
17
+ cms33: django-cms>=3.3,<3.4
18
+ cms34: django-cms>=3.4,<3.5
19
+ commands =
20
+ {envpython} --version
21
+ {env:COMMAND:coverage} erase
22
+ {env:COMMAND:coverage} run setup.py test
23
+ {env:COMMAND:coverage} report
24
+
25
+ [flake8]
26
+ max-line-length = 120
27
+ exclude = */docs/*,*/migrations/*
You can’t perform that action at this time.
0 commit comments