diff --git a/lib/package.gi b/lib/package.gi index 08e582e80c..fcd62953da 100644 --- a/lib/package.gi +++ b/lib/package.gi @@ -2206,6 +2206,9 @@ InstallGlobalFunction( ValidatePackageInfo, function( info ) x -> IsString(x) and Length(x) = 10 and x{ [3,6] } = "//" and ForAll( x{ [1,2,4,5,7,8,9,10] }, IsDigitChar ), "a string of the form `dd/mm/yyyy'" ); + TestOption( record, "License", + x -> IsString(x) and 0 < Length(x), + "a nonempty string containing an SPDX ID" ); TestMandat( record, "ArchiveURL", IsURL, "a string started with http://, https:// or ftp://" ); TestMandat( record, "ArchiveFormats", IsString, "a string" ); TestOption( record, "TextFiles", IsStringList, "a list of strings" ); diff --git a/tst/mockpkg/PackageInfo.g b/tst/mockpkg/PackageInfo.g index 02002fe8b2..597ab574c3 100644 --- a/tst/mockpkg/PackageInfo.g +++ b/tst/mockpkg/PackageInfo.g @@ -12,6 +12,7 @@ PackageName := "mockpkg", Subtitle := "A mock package for use by the GAP test suite", Version := "0.1", Date := "21/03/2018", # dd/mm/yyyy format +License := "GPL-2.0-or-later", Persons := [ rec(