mirror of
https://github.com/NaN-tic/trytond-country_zip.git
synced 2023-12-14 07:42:54 +01:00
Upgrade to 4.7
This commit is contained in:
parent
0785234969
commit
17a069d7a2
4 changed files with 70 additions and 24 deletions
58
.drone.yml
58
.drone.yml
|
@ -1,9 +1,51 @@
|
|||
image: python:all
|
||||
env:
|
||||
- POSTGRESQL_URI=postgresql://postgres@127.0.0.1:5432/
|
||||
- MYSQL_URI=mysql://root@127.0.0.1:3306/
|
||||
script:
|
||||
- pip install tox
|
||||
- tox -e "{py27,py33,py34,py35}-{sqlite,postgresql}" --skip-missing-interpreters
|
||||
clone:
|
||||
hg:
|
||||
image: plugins/hg
|
||||
|
||||
pipeline:
|
||||
tox:
|
||||
image: ${IMAGE}
|
||||
environment:
|
||||
- CFLAGS=-O0
|
||||
- DB_CACHE=/cache
|
||||
- TOX_TESTENV_PASSENV=CFLAGS DB_CACHE
|
||||
- POSTGRESQL_URI=postgresql://postgres@postgresql:5432/
|
||||
commands:
|
||||
- pip install tox
|
||||
- tox -e "${TOXENV}-${DATABASE}"
|
||||
volumes:
|
||||
- cache:/root/.cache
|
||||
|
||||
services:
|
||||
- postgres
|
||||
postgresql:
|
||||
image: postgres
|
||||
when:
|
||||
matrix:
|
||||
DATABASE: postgresql
|
||||
|
||||
matrix:
|
||||
include:
|
||||
- IMAGE: python:2.7
|
||||
TOXENV: py27
|
||||
DATABASE: sqlite
|
||||
- IMAGE: python:2.7
|
||||
TOXENV: py27
|
||||
DATABASE: postgresql
|
||||
- IMAGE: python:3.4
|
||||
TOXENV: py34
|
||||
DATABASE: sqlite
|
||||
- IMAGE: python:3.4
|
||||
TOXENV: py34
|
||||
DATABASE: postgresql
|
||||
- IMAGE: python:3.5
|
||||
TOXENV: py35
|
||||
DATABASE: sqlite
|
||||
- IMAGE: python:3.5
|
||||
TOXENV: py35
|
||||
DATABASE: postgresql
|
||||
- IMAGE: python:3.6
|
||||
TOXENV: py36
|
||||
DATABASE: sqlite
|
||||
- IMAGE: python:3.6
|
||||
TOXENV: py36
|
||||
DATABASE: postgresql
|
||||
|
|
30
setup.py
30
setup.py
|
@ -12,6 +12,8 @@ try:
|
|||
except ImportError:
|
||||
from ConfigParser import ConfigParser
|
||||
|
||||
MODULE = 'country_zip'
|
||||
PREFIX = 'trytonspain'
|
||||
MODULE2PREFIX = {}
|
||||
|
||||
|
||||
|
@ -20,6 +22,7 @@ def read(fname):
|
|||
os.path.join(os.path.dirname(__file__), fname),
|
||||
'r', encoding='utf-8').read()
|
||||
|
||||
|
||||
def get_require_version(name):
|
||||
if minor_version % 2:
|
||||
require = '%s >= %s.%s.dev0, < %s.%s'
|
||||
|
@ -39,8 +42,6 @@ version = info.get('version', '0.0.1')
|
|||
major_version, minor_version, _ = version.split('.', 2)
|
||||
major_version = int(major_version)
|
||||
minor_version = int(minor_version)
|
||||
name = 'trytonspain_country_zip'
|
||||
download_url = 'https://bitbucket.org/trytonspain/trytond-country_zip'
|
||||
|
||||
requires = []
|
||||
for dep in info.get('depends', []):
|
||||
|
@ -49,28 +50,28 @@ for dep in info.get('depends', []):
|
|||
requires.append(get_require_version('%s_%s' % (prefix, dep)))
|
||||
requires.append(get_require_version('trytond'))
|
||||
|
||||
tests_require = []
|
||||
tests_require = [get_require_version('proteus')]
|
||||
dependency_links = []
|
||||
if minor_version % 2:
|
||||
# Add development index for testing with proteus
|
||||
dependency_links.append('https://trydevpi.tryton.org/')
|
||||
|
||||
setup(name=name,
|
||||
setup(name='%s_%s' % (PREFIX, MODULE),
|
||||
version=version,
|
||||
description='Tryton Country Zip Module',
|
||||
description='Tryton country_zip Module',
|
||||
long_description=read('README'),
|
||||
author='TrytonSpain',
|
||||
author_email='info@trytonspain.com',
|
||||
url='https://bitbucket.org/trytonspain/',
|
||||
download_url=download_url,
|
||||
download_url="https://bitbucket.org/trytonspain/trytond-%s" % MODULE,
|
||||
keywords='',
|
||||
package_dir={'trytond.modules.country_zip': '.'},
|
||||
package_dir={'trytond.modules.%s' % MODULE: '.'},
|
||||
packages=[
|
||||
'trytond.modules.country_zip',
|
||||
'trytond.modules.country_zip.tests',
|
||||
'trytond.modules.%s' % MODULE,
|
||||
'trytond.modules.%s.tests' % MODULE,
|
||||
],
|
||||
package_data={
|
||||
'trytond.modules.country_zip': (info.get('xml', [])
|
||||
'trytond.modules.%s' % MODULE: (info.get('xml', [])
|
||||
+ ['tryton.cfg', 'view/*.xml', 'locale/*.po', '*.odt',
|
||||
'icons/*.svg', 'tests/*.rst']),
|
||||
},
|
||||
|
@ -97,9 +98,9 @@ setup(name=name,
|
|||
'Natural Language :: Spanish',
|
||||
'Operating System :: OS Independent',
|
||||
'Programming Language :: Python :: 2.7',
|
||||
'Programming Language :: Python :: 3.3',
|
||||
'Programming Language :: Python :: 3.4',
|
||||
'Programming Language :: Python :: 3.5',
|
||||
'Programming Language :: Python :: 3.6',
|
||||
'Programming Language :: Python :: Implementation :: CPython',
|
||||
'Programming Language :: Python :: Implementation :: PyPy',
|
||||
'Topic :: Office/Business',
|
||||
|
@ -110,10 +111,13 @@ setup(name=name,
|
|||
zip_safe=False,
|
||||
entry_points="""
|
||||
[trytond.modules]
|
||||
country_zip = trytond.modules.country_zip
|
||||
""",
|
||||
%s = trytond.modules.%s
|
||||
""" % (MODULE, MODULE),
|
||||
test_suite='tests',
|
||||
test_loader='trytond.test_loader:Loader',
|
||||
tests_require=tests_require,
|
||||
use_2to3=True,
|
||||
convert_2to3_doctests=[
|
||||
'tests/scenario_country_zip.rst',
|
||||
],
|
||||
)
|
||||
|
|
4
tox.ini
4
tox.ini
|
@ -1,10 +1,10 @@
|
|||
[tox]
|
||||
envlist = {py27,py33,py34,py35}-{sqlite,postgresql,mysql},pypy-{sqlite,postgresql}
|
||||
envlist = {py27,py34,py35,py36}-{sqlite,postgresql,mysql},pypy-{sqlite,postgresql}
|
||||
|
||||
[testenv]
|
||||
commands = {envpython} setup.py test
|
||||
deps =
|
||||
{py27,py33,py34,py35}-postgresql: psycopg2 >= 2.5
|
||||
{py27,py34,py35,py36}-postgresql: psycopg2 >= 2.5
|
||||
pypy-postgresql: psycopg2cffi >= 2.5
|
||||
mysql: MySQL-python
|
||||
sqlite: sqlitebck
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
[tryton]
|
||||
version=4.3.0
|
||||
version=4.7.0
|
||||
depends:
|
||||
party
|
||||
country
|
||||
|
|
Loading…
Reference in a new issue