[BACK]Return to licenses_test.go CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / pkgsrc / pkgtools / pkglint / files

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /pkgsrc/pkgtools/pkglint/files/licenses_test.go between version 1.11 and 1.12

version 1.11, 2018/03/24 14:32:49 version 1.12, 2018/04/28 23:32:52
Line 1 
Line 1 
 package main  package main
   
 import (  import (
         check "gopkg.in/check.v1"          "gopkg.in/check.v1"
 )  )
   
 func (s *Suite) Test_checklineLicense(c *check.C) {  func (s *Suite) Test_checklineLicense(c *check.C) {
Line 44  func (s *Suite) Test_checklineLicense(c 
Line 44  func (s *Suite) Test_checklineLicense(c 
   
         t.CheckOutputEmpty()          t.CheckOutputEmpty()
 }  }
   
   func (s *Suite) Test_checkToplevelUnusedLicenses(c *check.C) {
           t := s.Init(c)
   
           t.SetupFileLines("mk/bsd.pkg.mk", "# dummy")
           t.SetupFileLines("mk/fetch/sites.mk", "# dummy")
           t.SetupFileLines("mk/defaults/options.description", "option\tdescription")
           t.SetupFileLines("doc/TODO")
           t.SetupFileLines("mk/defaults/mk.conf")
           t.SetupFileLines("mk/tools/bsd.tools.mk",
                   ".include \"actual-tools.mk\"")
           t.SetupFileLines("mk/tools/actual-tools.mk")
           t.SetupFileLines("mk/tools/defaults.mk")
           t.SetupFileLines("mk/bsd.prefs.mk")
           t.SetupFileLines("mk/misc/category.mk")
           t.SetupFileLines("licenses/2-clause-bsd")
           t.SetupFileLines("licenses/gnu-gpl-v3")
   
           t.SetupFileLines("Makefile",
                   MkRcsID,
                   "SUBDIR+=\tcategory")
   
           t.SetupFileLines("category/Makefile",
                   MkRcsID,
                   "COMMENT=\tExample category",
                   "",
                   "SUBDIR+=\tpackage",
                   "",
                   ".include \"../mk/misc/category.mk\"")
   
           t.SetupFileLines("category/package/Makefile",
                   MkRcsID,
                   "CATEGORIES=\tcategory",
                   "",
                   "COMMENT=Example package",
                   "LICENSE=\t2-clause-bsd",
                   "NO_CHECKSUM=\tyes")
           t.SetupFileLines("category/package/PLIST",
                   PlistRcsID,
                   "bin/program")
   
           G.Main("pkglint", "-r", "-Cglobal", t.TmpDir())
   
           t.CheckOutputLines(
                   "WARN: ~/licenses/gnu-gpl-v3: This license seems to be unused.",
                   "0 errors and 1 warning found.")
   }

Legend:
Removed from v.1.11  
changed lines
  Added in v.1.12

CVSweb <webmaster@jp.NetBSD.org>