Separate TestKey the type from TestKeys the library of keys. Move web-of-trust test keys out of PublicKeyCheckerTest, since we will soon need to use them from GerritPublicKeyCheckerTest. But leave them out of TestKeys to limit the number of keys in that file, since most tests do not need to test the web of trust. Change-Id: If15ca85f8e7c16a56bbff08a3136f3b4adaf540c
		
			
				
	
	
		
			58 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			Python
		
	
	
	
	
	
			
		
		
	
	
			58 lines
		
	
	
		
			1.2 KiB
		
	
	
	
		
			Python
		
	
	
	
	
	
DEPS = [
 | 
						|
  '//gerrit-common:server',
 | 
						|
  '//gerrit-extension-api:api',
 | 
						|
  '//gerrit-reviewdb:server',
 | 
						|
  '//gerrit-server:server',
 | 
						|
  '//lib:guava',
 | 
						|
  '//lib:gwtorm',
 | 
						|
  '//lib/guice:guice',
 | 
						|
  '//lib/guice:guice-assistedinject',
 | 
						|
  '//lib/guice:guice-servlet',
 | 
						|
  '//lib/jgit:jgit',
 | 
						|
  '//lib/log:api',
 | 
						|
]
 | 
						|
 | 
						|
java_library(
 | 
						|
  name = 'gpg',
 | 
						|
  srcs = glob(['src/main/java/**/*.java']),
 | 
						|
  provided_deps = DEPS + [
 | 
						|
    '//lib/bouncycastle:bcpg',
 | 
						|
    '//lib/bouncycastle:bcprov',
 | 
						|
  ],
 | 
						|
  visibility = ['PUBLIC'],
 | 
						|
)
 | 
						|
 | 
						|
TESTUTIL_SRCS = glob(['src/test/**/testutil/**/*.java'])
 | 
						|
 | 
						|
java_library(
 | 
						|
  name = 'testutil',
 | 
						|
  srcs = TESTUTIL_SRCS,
 | 
						|
  deps = DEPS + [
 | 
						|
    ':gpg',
 | 
						|
    '//lib/bouncycastle:bcpg',
 | 
						|
    '//lib/bouncycastle:bcprov',
 | 
						|
  ],
 | 
						|
  visibility = ['PUBLIC'],
 | 
						|
)
 | 
						|
 | 
						|
java_test(
 | 
						|
  name = 'gpg_tests',
 | 
						|
  srcs = glob(
 | 
						|
    ['src/test/java/**/*.java'],
 | 
						|
    excludes = TESTUTIL_SRCS,
 | 
						|
  ),
 | 
						|
  deps = DEPS + [
 | 
						|
    ':gpg',
 | 
						|
    ':testutil',
 | 
						|
    '//gerrit-cache-h2:cache-h2',
 | 
						|
    '//gerrit-lucene:lucene',  
 | 
						|
    '//gerrit-server:testutil',
 | 
						|
    '//lib:truth',
 | 
						|
    '//lib/bouncycastle:bcpg',
 | 
						|
    '//lib/bouncycastle:bcprov',
 | 
						|
    '//lib/jgit:junit',
 | 
						|
  ],
 | 
						|
  source_under_test = [':gpg'],
 | 
						|
  visibility = ['//tools/eclipse:classpath'],
 | 
						|
)
 |