Skip to content

Commit b483f1d

Browse files
authored
Merge pull request #41 from nexB/32-update-boolean.py
Update boolean.py library
2 parents 538f083 + a9cb3ae commit b483f1d

8 files changed

+66
-45
lines changed

.travis.yml

Lines changed: 47 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,49 +1,67 @@
11
matrix:
22
include:
33
- os: osx
4-
language: generic
54
env:
6-
- PYENV_PYTHON="2.7.14"
5+
- PYTHON="3.6.8"
6+
- TEST_SUITE="bin/py.test -vvs"
7+
language: generic
8+
python:
79

810
- os: osx
9-
language: generic
1011
env:
11-
- PYENV_PYTHON="3.6.1"
12-
13-
- os: linux
12+
- PYTHON="2.7.15"
13+
- TEST_SUITE="bin/py.test -vvs"
1414
language: generic
15-
env:
16-
- PYENV_PYTHON="2.7.14"
15+
python:
1716

1817
- os: linux
19-
language: generic
20-
env:
21-
- PYENV_PYTHON="3.6.1"
18+
sudo: required
19+
env: TEST_SUITE="bin/py.test -vvs"
20+
language: python
21+
python: "2.7"
22+
dist: xenial
23+
24+
- os: linux
25+
sudo: required
26+
env: TEST_SUITE="bin/py.test -vvs"
27+
language: python
28+
python: "2.7"
29+
dist: bionic
30+
31+
- os: linux
32+
sudo: required
33+
env: TEST_SUITE="bin/py.test -vvs"
34+
language: python
35+
python: "3.6"
36+
dist: xenial
37+
38+
- os: linux
39+
sudo: required
40+
env: TEST_SUITE="bin/py.test -vvs"
41+
language: python
42+
python: "3.6"
43+
dist: bionic
2244

45+
addons:
46+
homebrew:
47+
packages:
48+
- openssl
49+
- readline
50+
- sqlite3
51+
- xz
52+
- zlib
53+
- pyenv
54+
update: true
2355

2456
install:
25-
- |
26-
if [[ $TRAVIS_OS_NAME == 'osx' ]]; then
27-
rm -rf ~/.pyenv
28-
git clone https://github.com/pyenv/pyenv.git ~/.pyenv
29-
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.bash_profile
30-
echo 'export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.bash_profile
31-
echo -e 'if command -v pyenv 1>/dev/null 2>&1; then\n eval "$(pyenv init -)"\nfi' >> ~/.bash_profile
32-
exec "$SHELL"
33-
fi
34-
- which pyenv
35-
- pyenv install --list
36-
- python --version
37-
- pyenv install "$PYENV_PYTHON"
38-
- pyenv global "$PYENV_PYTHON"
39-
- python --version
4057
- ./configure
4158

42-
4359
script:
60+
# If debugging, use a subset of tests to wait less:
61+
# - ./bin/py.test -n 2 -vvs --cov=src tests/scancode
62+
# - echo $TEST_SUITE
4463
- bin/about-code check --verbose .
45-
- "bin/py.test -vvs"
46-
64+
- $TEST_SUITE
4765

4866
notifications:
4967
irc:

azure-pipelines.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ jobs:
6262
python_version: '3.6'
6363
python_architecture: 'x86'
6464
py37:
65-
python_version: '3.7.3'
65+
python_version: '3.7.4'
6666
python_architecture: 'x86'
6767

6868
- template: etc/ci/azure-win.yml

tests/test_license_expression.py

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -552,6 +552,16 @@ def test_parse_simplify_and_contain_and_equal(self):
552552
expr3 = licensing.parse('mit and LGPL2.1')
553553
self.assertTrue(expr3 in expr2)
554554

555+
def test_parse_simplify_no_sort(self):
556+
licensing = Licensing()
557+
expr = licensing.parse('gpl-2.0 OR apache-2.0')
558+
expr2 = licensing.parse('apache-2.0 OR gpl-2.0')
559+
560+
self.assertEqual(expr, expr2)
561+
self.assertEqual(expr.simplify(), expr2.simplify())
562+
self.assertEqual(expr.simplify(sort=False), expr2.simplify())
563+
self.assertNotEqual(expr.simplify(sort=False).pretty(), expr2.pretty())
564+
555565
def test_license_expression_is_equivalent(self):
556566
lic = Licensing()
557567
is_equiv = lic.is_equivalent
-21.5 KB
Binary file not shown.

thirdparty/prod/boolean.py-3.6-py2.py3-none-any.whl.ABOUT

Lines changed: 0 additions & 15 deletions
This file was deleted.
21.6 KB
Binary file not shown.
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
about_resource: boolean.py-3.7-py2.py3-none-any.whl
2+
download_url: https://files.pythonhosted.org/packages/dc/53/b9c4f026bac231cbf7ddc214d879c3bdb5cda9a57adbe10520deeae4f154/boolean.py-3.7-py2.py3-none-any.whl
3+
attribute: yes
4+
checksum_md5: 97af5906f5eaa22539a034a99c24c824
5+
checksum_sha1: 514c2b60f10521988063a9e6b56e3fae24b393c7
6+
license_expression: bsd-simplified
7+
name: boolean.py
8+
version: '3.7'

0 commit comments

Comments
 (0)