File tree Expand file tree Collapse file tree 2 files changed +18
-39
lines changed Expand file tree Collapse file tree 2 files changed +18
-39
lines changed Original file line number Diff line number Diff line change 22
22
# Sort the entries below via IntelliJ's "Edit" -> "Sort Lines".
23
23
---
24
24
25
- # Ambiguous mappings (mapping reason not obvious without additional information)
26
- ALv2 : Apache-2.0
27
- ASL : Apache-2.0
28
- Apache-style : Apache-2.0
29
- Apache : Apache-2.0
30
- BSD-like : BSD-3-Clause
31
- BSD-style : BSD-3-Clause
32
- BSD : BSD-3-Clause
33
- GPL : GPL-2.0-or-later
34
- MPL : MPL-2.0
35
- afl : AFL-3.0
36
- agpl : AGPL-3.0-or-later
37
- apache-license : Apache-2.0
38
- bsd-license : BSD-3-Clause
39
- bsd-licensed : BSD-3-Clause
40
- cddl : CDDL-1.0
41
- efl : EFL-2.0
42
- epl : EPL-1.0
43
- eupl : EUPL-1.0
44
- fdl : GFDL-1.3-or-later
45
- gfdl : GFDL-1.3-or-later
46
- gpl-license : GPL-2.0-or-later
47
- psf : PSF-2.0
48
- psfl : PSF-2.0
49
- python : Python-2.0
50
-
51
- # Non-ambiguous mappings
52
25
AFLv2.1 : AFL-2.1
26
+ ALv2 : Apache-2.0
53
27
APACHEv2 : Apache-2.0
54
28
APL2 : Apache-2.0
55
29
APLv2.0 : Apache-2.0
@@ -59,11 +33,7 @@ Apache2: Apache-2.0
59
33
BSD-3 : BSD-3-Clause
60
34
BSD2 : BSD-2-Clause
61
35
BSD3 : BSD-3-Clause
62
- Boost : BSL-1.0
63
36
Bouncy : MIT
64
- CC0 : CC0-1.0
65
- CPL : CPL-1.0
66
- CeCILL : CECILL-1.1
67
37
EDL-1.0 : BSD-3-Clause
68
38
FreeBSD : BSD-2-Clause-Views
69
39
GPL-2 : GPL-2.0-only
@@ -74,31 +44,24 @@ GPLv3+: GPL-3.0-or-later
74
44
GPLv3 : GPL-3.0-only
75
45
ISCL : ISC
76
46
LGPL-3 : LGPL-3.0-only
77
- LGPL2 : LGPL-2.1-only
78
47
LGPL3 : LGPL-3.0-only
79
- LGPL : LGPL-2.0-or-later
80
- LGPLv2 : LGPL-2.1-only
81
48
LGPLv3+ : LGPL-3.0-or-later
82
49
LGPLv3 : LGPL-3.0-only
83
50
MIT-like : MIT
84
51
MIT-style : MIT
85
52
MPLv2.0 : MPL-2.0
86
53
MPLv2 : MPL-2.0
87
- ODBL : ODbL-1.0
88
54
PSF2 : PSF-2.0
89
55
UNLICENSED : Unlicense
90
56
Unlicence : Unlicense
91
- Vovida : VSL-1.0
92
57
afl-2 : AFL-2.0
93
58
afl2.0 : AFL-2.0
94
59
afl2.1 : AFL-2.1
95
60
afl2 : AFL-2.0
96
61
bouncy-license : MIT
97
62
bsl1.0 : BSL-1.0
98
- bsl : BSL-1.0
99
63
cddl1.0 : CDDL-1.0
100
64
cddl1.1 : CDDL-1.1
101
- cpal : CPAL-1.0
102
65
epl1.0 : EPL-1.0
103
66
epl2.0 : EPL-2.0
104
67
eupl1.0 : EUPL-1.0
@@ -113,4 +76,3 @@ mpl2.0: MPL-2.0
113
76
mpl2 : MPL-2.0
114
77
w3cl : W3C
115
78
wtf : WTFPL
116
- zope : ZPL-2.1
Original file line number Diff line number Diff line change @@ -57,6 +57,23 @@ class SpdxSimpleLicenseMappingTest : WordSpec({
57
57
if (license.id.endsWith("-only")) key should containADigit()
58
58
}
59
59
}
60
+
61
+ " contain matching digits disregarding trailing zeros" {
62
+ val exceptions = mapOf(
63
+ // See https://www.eclipse.org/org/documents/edl-v10.php.
64
+ "EDL -1.0" to SpdxLicense .BSD_3_CLAUSE ,
65
+ // See https://spdx.org/licenses/BSD -2-Clause -Views .html.
66
+ "FreeBSD " to SpdxLicense .BSD_2_CLAUSE_VIEWS
67
+ )
68
+
69
+ SpdxSimpleLicenseMapping .simpleLicenseMapping.filterNot {
70
+ it in exceptions.entries
71
+ }.forAll { (key, license) ->
72
+ val digitsInKey = key.filter { it.isDigit() }.dropLastWhile { it == ' 0' }
73
+ val digitsInLicense = license.id.filter { it.isDigit() }.dropLastWhile { it == ' 0' }
74
+ digitsInKey shouldBe digitsInLicense
75
+ }
76
+ }
60
77
}
61
78
62
79
" The simple expression mapping" should {
You can’t perform that action at this time.
0 commit comments