Closed goneall closed 3 years ago
Hi Gary -- I don't know if this helps, but for my local tests during development I've been using the script that Kyle added directly to the license-list-XML repo a while back:
https://github.com/spdx/license-list-XML/blob/master/test-one-license
which brute-forces things by renaming all files from "whatever.xml" to "whatever.xml.skip", except the one that is being tested.
Given that, I'm kind of okay with the CI tests doing the full set of tests on PR submission / merge, particularly if that's needed to do the "compare against other licenses" check. The script linked above is useful for doing the local development of templates.
@swinslow Thanks for pointing this out, I never noticed the script.
If you don't mind downloading and running a Java application, there is even a faster and more straightforward way of testing a single file:
java -jar licenseListPublisher-2.1.23-jar-with-dependencies.jar LicenseRDFAGenerator src/LICENSESOURCE.xml TEMPOUTPUTDIR v4.0 22-Feb-2021 test/simpleTestForGenerator
This assumes your running the command from the root of the License-List-XML repo. Replace LICENSESOURCE with the license ID you want to run and replace TEMPOUTPUTDIR with a valid existing directory.
Resolved with PR #96
When publishing a single file, there is not a comparison against the other files in the repo. An additional check should be added. If there are additional files in the license-list-xml repo, they could be compiled and compared. This, however, would be a performance issue.
Another possibility is to compare against the existing license list. Matches to the same license ID's should be ignored.