Skip to content

Commit

Permalink
Added buildout with travis and coverage test
Browse files Browse the repository at this point in the history
  • Loading branch information
tomgross committed Aug 24, 2016
1 parent f3ec0f3 commit 1ff7af6
Show file tree
Hide file tree
Showing 8 changed files with 70 additions and 4 deletions.
10 changes: 10 additions & 0 deletions .coveragerc
@@ -0,0 +1,10 @@
[report]
omit =
/home/*/.buildout/eggs/*
/usr/*
bin/test
/home/travis/buildout-cache/eggs/*
/home/travis/virtualenv/*
eggs/*
parts/*

8 changes: 7 additions & 1 deletion .gitignore
Expand Up @@ -2,4 +2,10 @@ plone.formwidget.multifile.egg-info
build
dist
*.mo
*.pyc
*.py[co]
.*.cfg
bin
parts
develop-eggs
htmlcov
.coverage
26 changes: 26 additions & 0 deletions .travis.yml
@@ -0,0 +1,26 @@
language: python
python: 2.7
sudo: false
cache:
directories:
- eggs
- parts/node
env:
matrix:
- PLONE_VERSION=4.3
- PLONE_VERSION=5.0
- PLONE_VERSION=5.1
before_install:
- virtualenv .
- bin/pip install --upgrade pip setuptools zc.buildout
- if [ $PLONE_VERSION == 5.0 ]; then pip install --upgrade setuptools==21.0.0; fi
install:
- sed -ie "s#test-4.3#test-$PLONE_VERSION#" buildout.cfg
- bin/buildout annotate
- bin/buildout
script:
- bin/test
after_success:
- bin/pip install -q coveralls python-coveralls
- bin/createcoverage
- coveralls
1 change: 1 addition & 0 deletions README.rst
14 changes: 14 additions & 0 deletions buildout.cfg
@@ -0,0 +1,14 @@
[buildout]
extends = https://raw.github.com/collective/buildout.plonetest/master/test-5.1.x.cfg
package-name = plone.formwidget.multifile
package-extras = [tests]
parts +=
createcoverage

[createcoverage]
recipe = zc.recipe.egg
eggs = createcoverage

[versions]
coverage = 3.7

5 changes: 5 additions & 0 deletions docs/HISTORY.txt
Expand Up @@ -15,6 +15,11 @@ Incompatibilities:
- Add French and Dutch translations
[laulaz]

- Add travis hook
[tomgross]

- Plone 5.0 support
[tomgross]

1.1 (2014-03-24)
----------------
Expand Down
4 changes: 2 additions & 2 deletions plone/formwidget/multifile/README.txt
Expand Up @@ -86,8 +86,8 @@ names. We have to make sure ``MultiFileConverter.toFieldValue`` won't break in t
>>> widget.context = MockContent()
>>> widget.form.context = MockContent()
>>> converter = MultiFileConverter(IMockContent['file'], widget)
>>> converter.toFieldValue([u'', u'filename1.txt', u'filename2.txt'])
[]
>>> [f.data for f in converter.toFieldValue([u'', u'filename1.txt', u'filename2.txt'])]
['filename1.txt', 'filename2.txt']

AJAX form validation on object creation
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Expand Down
6 changes: 5 additions & 1 deletion setup.py
Expand Up @@ -15,11 +15,15 @@
open(os.path.join("docs", "HISTORY.txt")).read(),
classifiers=[
"Programming Language :: Python",
"Programming Language :: Python :: 2.7",
"Framework :: Plone",
"Framework :: Plone :: 4.3",
"Framework :: Plone :: 5.0",
],
keywords='',
author='Jonas Baumann',
author_email='j.baumann@4teamwork.ch',
url='http://github.com/plone/plone.formwidget.multifile',
url='https://github.com/plone/plone.formwidget.multifile',
license='GPL',
packages=find_packages(exclude=['ez_setup']),
namespace_packages=['plone', 'plone.formwidget'],
Expand Down

0 comments on commit 1ff7af6

Please sign in to comment.