PMD Results

The following document contains the results of PMD 7.17.0.

Violations By Priority

Priority 1

civitas.common - civitas/bboard/server/RestTemplateResponseErrorHandler.java

Rule Violation Line
AvoidThrowingRawExceptionTypes Avoid throwing raw exception type Error. 33

civitas.common - civitas/bboard/server/controllers/CloseBoardController.java

Rule Violation Line
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 58

civitas.common - civitas/common/mix/elementrevelation/VerifyMixElementRevelation.java

Rule Violation Line
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 36

civitas.common - civitas/common/mix/revelation/GetMixRevelationMeta.java

Rule Violation Line
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 23

civitas.common - civitas/common/mix/voteelementrevelation/VerifyMixVoteElementRevelation.java

Rule Violation Line
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 28

civitas.common - civitas/common/mix/votemix/AddVoteAndCommitmentToVoteMix.java

Rule Violation Line
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 20

civitas.common - civitas/common/mix/votemix/GetReencryptedVoteFromMix.java

Rule Violation Line
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 25

civitas.common - civitas/common/mix/votemix/GetVoteMixMeta.java

Rule Violation Line
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 20

civitas.common - civitas/common/votercapabilitysharesandproofs/VerifyVoterCapabilitySharesAndProof.java

Rule Violation Line
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 42

Priority 3

civitas.common - civitas/bboard/common/BBPostRepository.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 5

civitas.common - civitas/bboard/common/VerifyBBPost.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 20

civitas.common - civitas/bboard/server/BoardRepository.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 5

civitas.common - civitas/bboard/server/GetBoardForId.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 9

civitas.common - civitas/bboard/server/RestTemplateResponseErrorHandler.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 15
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 28

civitas.common - civitas/bboard/server/controllers/CloseBoardController.java

Rule Violation Line
PreserveStackTrace Thrown exception does not preserve the stack trace of exception 'e' on all code paths 70
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 77
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 77

civitas.common - civitas/bboard/server/controllers/CommunicableExceptionHandler.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 12

civitas.common - civitas/bboard/server/controllers/GetRestTemplate.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11

civitas.common - civitas/bboard/server/controllers/NewBoardController.java

Rule Violation Line
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 33

civitas.common - civitas/bboard/server/controllers/PostController.java

Rule Violation Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 1138
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 89
PreserveStackTrace Thrown exception does not preserve the stack trace of exception 'e' on all code paths 93
PreserveStackTrace Thrown exception does not preserve the stack trace of exception 'e' on all code paths 115
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 135

civitas.common - civitas/bboard/server/controllers/RetrieveHashController.java

Rule Violation Line
UnusedPrivateMethod Avoid unused private methods such as 'apply(String, Long, Long, String)'. 51
PreserveStackTrace Thrown exception does not preserve the stack trace of exception 'e' on all code paths 82

civitas.common - civitas/bboard/server/controllers/RetrievePostsController.java

Rule Violation Line
UnusedPrivateMethod Avoid unused private methods such as 'apply(String)'. 21

civitas.common - civitas/bboard/server/electioncache/ElectionCacheRepository.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 7

civitas.common - civitas/bboard/server/electioncache/UpdateCache.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 15

civitas.common - civitas/common/CheckAccess.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 6

civitas.common - civitas/common/Configuration.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 7

civitas.common - civitas/common/ConvertFromXml.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 15

civitas.common - civitas/common/ConvertToXml.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 12

civitas.common - civitas/common/GetPrivateKey.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 19
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 24

civitas.common - civitas/common/GetPublicKey.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 18
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 22

civitas.common - civitas/common/LoggerService.java

Rule Violation Line
ServiceClassField Services have only @Autowired fields 11

civitas.common - civitas/common/ballot/CreateEmptyBallot.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 10
AvoidLiteralsInIfCondition Avoid using literals such as 2 in if statements 16

civitas.common - civitas/common/ballot/RecordOnePairInBallot.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11

civitas.common - civitas/common/ballotdesign/CalculateBallotLength.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 6

civitas.common - civitas/common/ballotdesign/CalculatePositionInBallot.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 6

civitas.common - civitas/common/ballotdesign/CheckBallotAgainstBallotDesign.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11

civitas.common - civitas/common/ballotdesign/CreateBallotDesign.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3

civitas.common - civitas/common/ballotdesign/DecomposeBallot.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 25
LooseCoupling Avoid using implementation types like 'CiphertextList'; use the interface instead 50
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 8081

civitas.common - civitas/common/ballotdesign/GetIndexOfCandidate.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3
CompareObjectsWithEquals Use equals() to compare object references. 7
UseEqualsToCompareStrings Use equals() to compare strings instead of '==' or '!=' 7

civitas.common - civitas/common/ballotdesign/GetNthContext.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 8

civitas.common - civitas/common/ballotdesign/ListContextsNeeded.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 8

civitas.common - civitas/common/ballotdesign/TallyVote.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 18
CyclomaticComplexity The method 'apply(String, ElGamalMsg, String, TallyState, Map<CivitasBigInteger, VoteChoice>)' has a cyclomatic complexity of 14. 26
PreserveStackTrace Thrown exception does not preserve the stack trace of exception 'e' on all code paths 57

civitas.common - civitas/common/board/GetContentCommitmentForBoard.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3

civitas.common - civitas/common/capabilityencryption/EncryptCapability.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 16

civitas.common - civitas/common/election/GetBaseContext.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 6

civitas.common - civitas/common/election/GetBlockName.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 9

civitas.common - civitas/common/election/GetContextForBlock.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 9

civitas.common - civitas/common/election/GetElectionAbandonmentReporter.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3

civitas.common - civitas/common/election/GetVoterBlockForBlock.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 9

civitas.common - civitas/common/election/IsVoterSubmissionInBlock.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11

civitas.common - civitas/common/electionresults/GetComputerForTeller.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 6

civitas.common - civitas/common/electionresults/GetMetaForTeller.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 9

civitas.common - civitas/common/electoralroll/GetMetaForElectoralRollCapabilityShares.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 5

civitas.common - civitas/common/encryptedchoice/EncryptChoice.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 15
LooseCoupling Avoid using implementation types like 'CiphertextList'; use the interface instead 24

civitas.common - civitas/common/mix/AddCommitmentToMix.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 8

civitas.common - civitas/common/mix/capabilityelementrevelation/VerifyMixCapabilityElementRevelation.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 13

civitas.common - civitas/common/mix/capabilitymix/AddEncryptedCapability.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 7

civitas.common - civitas/common/mix/capabilitymix/GetCapabilityMixMeta.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11

civitas.common - civitas/common/mix/capabilitymix/GetMixConfirmationMeta.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 5

civitas.common - civitas/common/mix/capabilitymix/GetReencryptedCapabilityMix.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 12

civitas.common - civitas/common/mix/elementrevelation/VerifyMixElementRevelation.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 17

civitas.common - civitas/common/mix/hashrevelation/GetMetaForMixHashRevelation.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11

civitas.common - civitas/common/mix/revelation/GetMixRevelationMeta.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 12

civitas.common - civitas/common/mix/revelation/VerifyMixRevelation.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 16
CyclomaticComplexity The method 'apply(MixRevelation, ElGamalPublicKey, VoterMix, VoterMix, VoterMix, boolean[])' has a cyclomatic complexity of 10. 23
UnusedAssignment The initializer for variable 'fromIndex' is never used (overwritten on lines 54 and 60) 45
UnusedAssignment The initializer for variable 'toIndex' is never used (overwritten on lines 55 and 61) 46
UnusedAssignment The initializer for variable 'fromMix' is never used (overwritten on lines 52 and 58) 47
UnusedAssignment The initializer for variable 'toMix' is never used (overwritten on lines 53 and 59) 48

civitas.common - civitas/common/mix/voteelementrevelation/VerifyMixVoteElementRevelation.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 15

civitas.common - civitas/common/mix/votemix/AddVoteAndCommitmentToVoteMix.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11

civitas.common - civitas/common/mix/votemix/AddVoteToVoteMix.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11

civitas.common - civitas/common/mix/votemix/GetReencryptedVoteFromMix.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 13

civitas.common - civitas/common/mix/votemix/GetVoteMixMeta.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 12

civitas.common - civitas/common/tabteller/ConstructTabTellerKeyShareCommitment.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 13
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 25

civitas.common - civitas/common/tabteller/voterblockcontents/GetTabTellerVoterBlockContentsMeta.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3

civitas.common - civitas/common/tallystate/CreateTallyState.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 5

civitas.common - civitas/common/tallystate/RecordBeat.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 6

civitas.common - civitas/common/verifiablevote/VerifyVerifiableVote.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 12
LooseCoupling Avoid using implementation types like 'CiphertextList'; use the interface instead 20

civitas.common - civitas/common/votercapabilitysharesandproofs/VerifyVoterCapabilitySharesAndProof.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 20
CyclomaticComplexity The method 'apply(VoterCapabilitySharesAndProof, ElGamalSignedCiphertext[], ElGamalPublicKey, ElGamalPublicKey, String, int)' has a cyclomatic complexity of 11. 34
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 51

civitas.common - civitas/common/votersubmission/CheckVoterSubmission.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 16
LooseCoupling Avoid using implementation types like 'CiphertextList'; use the interface instead 28
CognitiveComplexity The method 'apply(BallotDesign, VoterSubmission, int, String, CiphertextList, ElGamalPublicKey)' has a cognitive complexity of 15, current threshold is 15 33
CyclomaticComplexity The method 'apply(BallotDesign, VoterSubmission, int, String, CiphertextList, ElGamalPublicKey)' has a cyclomatic complexity of 15. 33
LooseCoupling Avoid using implementation types like 'CiphertextList'; use the interface instead 38

civitas.common - civitas/common/votersubmission/CreateVoterSubmission.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 8

civitas.common - civitas/common/votersubmission/GetMetaForVoterSubmission.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 6

civitas.common - civitas/result/CalculateStrengths.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 8

civitas.common - civitas/result/CalculateWinnerList.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11
LinguisticNaming Linguistics Antipattern - The field 'isFullyIgnored' indicates linguistically it is a boolean, but it is 'IsFullyIgnored' 22
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 34

civitas.common - civitas/result/CompareBeats.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 6

civitas.common - civitas/result/ComputeWinners.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 10

civitas.common - civitas/result/FormatResult.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 9
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 15
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 17

civitas.common - civitas/result/InitialMatrix.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 6
CompareObjectsWithEquals Use equals() to compare object references. 14

civitas.common - civitas/result/IsFullyIgnored.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 6

civitas.common - civitas/result/MakeCloudWordList.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 9
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 16

civitas.common - civitas/result/Max.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 7

civitas.common - civitas/result/Min.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 7

civitas.common - civitas/result/TransitiveClosure.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 7

civitas.common - civitas/util/CivitasBigIntegerDeserializer.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 12

civitas.common - civitas/util/CivitasBigIntegerSerializer.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11

civitas.common - civitas/util/GetReaderForFile.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11

civitas.common - civitas/AppTestConfig.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 12

civitas.common - civitas/WebAppTestConfig.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 13

civitas.common - civitas/bboard/common/VerifyBBPostTest.java

Rule Violation Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 26
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 28

civitas.common - civitas/bboard/server/EndToEndTest.java

Rule Violation Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 1156
SingularField Perhaps 'keys' could be replaced by a local variable. 82
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 105
LinguisticNaming Linguistics Antipattern - The getter 'getTestKeys' should not return void linguistically 139
DetachedTestCase Probable detached JUnit test case. 139

civitas.common - civitas/bboard/server/controllers/CloseBoardControllerTest.java

Rule Violation Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 37
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 44
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 44
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 46
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 46
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 53
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 98

civitas.common - civitas/bboard/server/controllers/EnvDependentAnswer.java

Rule Violation Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 11
AvoidFieldNameMatchingMethodName Field answer has the same name as a method 13

civitas.common - civitas/bboard/server/controllers/PostControllerTest.java

Rule Violation Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 40
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 55
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 102

civitas.common - civitas/common/ballotdesign/DecomposeBallotTest.java

Rule Violation Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 35

civitas.common - civitas/common/ballotdesign/GetIndexOfCandidateTest.java

Rule Violation Line
UseLocaleWithCaseConversions When doing a String.toLowerCase()/toUpperCase() call, use a Locale 26

civitas.common - civitas/common/capabilityencryption/EncryptCapabilityStub.java

Rule Violation Line
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 1516

civitas.common - civitas/common/capabilityencryption/EncryptCapabilityTest.java

Rule Violation Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 26

civitas.common - civitas/common/election/IsVoterSubmissionInBlockTest.java

Rule Violation Line
TooManyMethods This class has too many methods, consider refactoring it. 2199
LinguisticNaming Linguistics Antipattern - The field 'isVoterSubmissionInBlock' indicates linguistically it is a boolean, but it is 'IsVoterSubmissionInBlock' 24
AvoidDuplicateLiterals The String literal "(version with context)" appears 4 times in this file; the first occurrence is on line 47 47
AvoidDuplicateLiterals The String literal "(version with encrypted capabilities)" appears 4 times in this file; the first occurrence is on line 74 74

civitas.common - civitas/common/encryptedchoice/EncryptChoiceStub.java

Rule Violation Line
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 1719

civitas.common - civitas/common/encryptedchoice/EncryptChoiceTest.java

Rule Violation Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 28

civitas.common - civitas/common/mix/capabilitymix/AddCommitmentToMixTest.java

Rule Violation Line
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 20

civitas.common - civitas/common/mix/revelation/VerifyMixRevelationTest.java

Rule Violation Line
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 37
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 49
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 62
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 74
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 86
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 98
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 110

civitas.common - civitas/common/mix/voteelementrevelation/VerifyMixVoteElementRevelationTest.java

Rule Violation Line
TooManyMethods This class has too many methods, consider refactoring it. 17112

civitas.common - civitas/common/mix/votemix/AddVoteAndCommitmentToVoteMixTest.java

Rule Violation Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 20

civitas.common - civitas/common/votercapabilitysharesandproofs/VerifyVoterCapabilitySharesAndProofTest.java

Rule Violation Line
TooManyMethods This class has too many methods, consider refactoring it. 16182

civitas.common - civitas/functionaltests/CreatePermutationFunctionalTest.java

Rule Violation Line
AvoidFieldNameMatchingMethodName Field createPermutation has the same name as a method 28
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 32
LinguisticNaming Linguistics Antipattern - The variable 'hasIt' indicates linguistically it is a boolean, but it is 'boolean[]' 35
UnnecessaryBooleanAssertion assertTrue(true) or similar statements are unnecessary 45

civitas.common - civitas/functionaltests/GenerateSafePrimeFunctionalTest.java

Rule Violation Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 38

civitas.common - civitas/functionaltests/GenerateSchnorrPrimeFunctionalTest.java

Rule Violation Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 32

civitas.common - civitas/result/ComputeWinnersFunctionalTest.java

Rule Violation Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 45

civitas.common - civitas/util/ObtainProbablePrimeFunctionalTest.java

Rule Violation Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 29

Priority 4

civitas.common - civitas/common/mix/revelation/VerifyMixRevelation.java

Rule Violation Line
UseVarargs Consider using varargs for methods or constructors which take an array the last parameter. 29

civitas.common - civitas/result/ComputeWinners.java

Rule Violation Line
UseVarargs Consider using varargs for methods or constructors which take an array the last parameter. 15

civitas.common - civitas/result/Max.java

Rule Violation Line
ShortClassName Avoid short class names like Max 7

civitas.common - civitas/result/Min.java

Rule Violation Line
ShortClassName Avoid short class names like Min 7

Files

civitas.common - civitas/bboard/common/BBPostRepository.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 5

civitas.common - civitas/bboard/common/VerifyBBPost.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 20

civitas.common - civitas/bboard/server/BoardRepository.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 5

civitas.common - civitas/bboard/server/GetBoardForId.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 9

civitas.common - civitas/bboard/server/RestTemplateResponseErrorHandler.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 15
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 28
AvoidThrowingRawExceptionTypes Avoid throwing raw exception type Error. 1 33

civitas.common - civitas/bboard/server/controllers/CloseBoardController.java

Rule Violation Priority Line
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 1 58
PreserveStackTrace Thrown exception does not preserve the stack trace of exception 'e' on all code paths 3 70
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 77
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 77

civitas.common - civitas/bboard/server/controllers/CommunicableExceptionHandler.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 12

civitas.common - civitas/bboard/server/controllers/GetRestTemplate.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11

civitas.common - civitas/bboard/server/controllers/NewBoardController.java

Rule Violation Priority Line
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 3 33

civitas.common - civitas/bboard/server/controllers/PostController.java

Rule Violation Priority Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 3 1138
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 89
PreserveStackTrace Thrown exception does not preserve the stack trace of exception 'e' on all code paths 3 93
PreserveStackTrace Thrown exception does not preserve the stack trace of exception 'e' on all code paths 3 115
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 135

civitas.common - civitas/bboard/server/controllers/RetrieveHashController.java

Rule Violation Priority Line
UnusedPrivateMethod Avoid unused private methods such as 'apply(String, Long, Long, String)'. 3 51
PreserveStackTrace Thrown exception does not preserve the stack trace of exception 'e' on all code paths 3 82

civitas.common - civitas/bboard/server/controllers/RetrievePostsController.java

Rule Violation Priority Line
UnusedPrivateMethod Avoid unused private methods such as 'apply(String)'. 3 21

civitas.common - civitas/bboard/server/electioncache/ElectionCacheRepository.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 7

civitas.common - civitas/bboard/server/electioncache/UpdateCache.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 15

civitas.common - civitas/common/CheckAccess.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 6

civitas.common - civitas/common/Configuration.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 7

civitas.common - civitas/common/ConvertFromXml.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 15

civitas.common - civitas/common/ConvertToXml.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 12

civitas.common - civitas/common/GetPrivateKey.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 19
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 24

civitas.common - civitas/common/GetPublicKey.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 18
UseConcurrentHashMap If you run in Java5 or newer and have concurrent access, you should use the ConcurrentHashMap implementation 3 22

civitas.common - civitas/common/LoggerService.java

Rule Violation Priority Line
ServiceClassField Services have only @Autowired fields 3 11

civitas.common - civitas/common/ballot/CreateEmptyBallot.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 10
AvoidLiteralsInIfCondition Avoid using literals such as 2 in if statements 3 16

civitas.common - civitas/common/ballot/RecordOnePairInBallot.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11

civitas.common - civitas/common/ballotdesign/CalculateBallotLength.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 6

civitas.common - civitas/common/ballotdesign/CalculatePositionInBallot.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 6

civitas.common - civitas/common/ballotdesign/CheckBallotAgainstBallotDesign.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11

civitas.common - civitas/common/ballotdesign/CreateBallotDesign.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 3

civitas.common - civitas/common/ballotdesign/DecomposeBallot.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 25
LooseCoupling Avoid using implementation types like 'CiphertextList'; use the interface instead 3 50
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 3 8081

civitas.common - civitas/common/ballotdesign/GetIndexOfCandidate.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 3
CompareObjectsWithEquals Use equals() to compare object references. 3 7
UseEqualsToCompareStrings Use equals() to compare strings instead of '==' or '!=' 3 7

civitas.common - civitas/common/ballotdesign/GetNthContext.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 8

civitas.common - civitas/common/ballotdesign/ListContextsNeeded.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 8

civitas.common - civitas/common/ballotdesign/TallyVote.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 18
CyclomaticComplexity The method 'apply(String, ElGamalMsg, String, TallyState, Map<CivitasBigInteger, VoteChoice>)' has a cyclomatic complexity of 14. 3 26
PreserveStackTrace Thrown exception does not preserve the stack trace of exception 'e' on all code paths 3 57

civitas.common - civitas/common/board/GetContentCommitmentForBoard.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 3

civitas.common - civitas/common/capabilityencryption/EncryptCapability.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 16

civitas.common - civitas/common/election/GetBaseContext.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 6

civitas.common - civitas/common/election/GetBlockName.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 9

civitas.common - civitas/common/election/GetContextForBlock.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 9

civitas.common - civitas/common/election/GetElectionAbandonmentReporter.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 3

civitas.common - civitas/common/election/GetVoterBlockForBlock.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 9

civitas.common - civitas/common/election/IsVoterSubmissionInBlock.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11

civitas.common - civitas/common/electionresults/GetComputerForTeller.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 6

civitas.common - civitas/common/electionresults/GetMetaForTeller.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 9

civitas.common - civitas/common/electoralroll/GetMetaForElectoralRollCapabilityShares.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 5

civitas.common - civitas/common/encryptedchoice/EncryptChoice.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 15
LooseCoupling Avoid using implementation types like 'CiphertextList'; use the interface instead 3 24

civitas.common - civitas/common/mix/AddCommitmentToMix.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 8

civitas.common - civitas/common/mix/capabilityelementrevelation/VerifyMixCapabilityElementRevelation.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 13

civitas.common - civitas/common/mix/capabilitymix/AddEncryptedCapability.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 7

civitas.common - civitas/common/mix/capabilitymix/GetCapabilityMixMeta.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11

civitas.common - civitas/common/mix/capabilitymix/GetMixConfirmationMeta.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 5

civitas.common - civitas/common/mix/capabilitymix/GetReencryptedCapabilityMix.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 12

civitas.common - civitas/common/mix/elementrevelation/VerifyMixElementRevelation.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 17
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 1 36

civitas.common - civitas/common/mix/hashrevelation/GetMetaForMixHashRevelation.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11

civitas.common - civitas/common/mix/revelation/GetMixRevelationMeta.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 12
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 1 23

civitas.common - civitas/common/mix/revelation/VerifyMixRevelation.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 16
CyclomaticComplexity The method 'apply(MixRevelation, ElGamalPublicKey, VoterMix, VoterMix, VoterMix, boolean[])' has a cyclomatic complexity of 10. 3 23
UseVarargs Consider using varargs for methods or constructors which take an array the last parameter. 4 29
UnusedAssignment The initializer for variable 'fromIndex' is never used (overwritten on lines 54 and 60) 3 45
UnusedAssignment The initializer for variable 'toIndex' is never used (overwritten on lines 55 and 61) 3 46
UnusedAssignment The initializer for variable 'fromMix' is never used (overwritten on lines 52 and 58) 3 47
UnusedAssignment The initializer for variable 'toMix' is never used (overwritten on lines 53 and 59) 3 48

civitas.common - civitas/common/mix/voteelementrevelation/VerifyMixVoteElementRevelation.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 15
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 1 28

civitas.common - civitas/common/mix/votemix/AddVoteAndCommitmentToVoteMix.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 1 20

civitas.common - civitas/common/mix/votemix/AddVoteToVoteMix.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11

civitas.common - civitas/common/mix/votemix/GetReencryptedVoteFromMix.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 13
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 1 25

civitas.common - civitas/common/mix/votemix/GetVoteMixMeta.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 12
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 1 20

civitas.common - civitas/common/tabteller/ConstructTabTellerKeyShareCommitment.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 13
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 25

civitas.common - civitas/common/tabteller/voterblockcontents/GetTabTellerVoterBlockContentsMeta.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 3

civitas.common - civitas/common/tallystate/CreateTallyState.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 5

civitas.common - civitas/common/tallystate/RecordBeat.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 6

civitas.common - civitas/common/verifiablevote/VerifyVerifiableVote.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 12
LooseCoupling Avoid using implementation types like 'CiphertextList'; use the interface instead 3 20

civitas.common - civitas/common/votercapabilitysharesandproofs/VerifyVoterCapabilitySharesAndProof.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 20
CyclomaticComplexity The method 'apply(VoterCapabilitySharesAndProof, ElGamalSignedCiphertext[], ElGamalPublicKey, ElGamalPublicKey, String, int)' has a cyclomatic complexity of 11. 3 34
AvoidThrowingNullPointerException Avoid throwing null pointer exceptions. 1 42
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 51

civitas.common - civitas/common/votersubmission/CheckVoterSubmission.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 16
LooseCoupling Avoid using implementation types like 'CiphertextList'; use the interface instead 3 28
CognitiveComplexity The method 'apply(BallotDesign, VoterSubmission, int, String, CiphertextList, ElGamalPublicKey)' has a cognitive complexity of 15, current threshold is 15 3 33
CyclomaticComplexity The method 'apply(BallotDesign, VoterSubmission, int, String, CiphertextList, ElGamalPublicKey)' has a cyclomatic complexity of 15. 3 33
LooseCoupling Avoid using implementation types like 'CiphertextList'; use the interface instead 3 38

civitas.common - civitas/common/votersubmission/CreateVoterSubmission.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 8

civitas.common - civitas/common/votersubmission/GetMetaForVoterSubmission.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 6

civitas.common - civitas/result/CalculateStrengths.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 8

civitas.common - civitas/result/CalculateWinnerList.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11
LinguisticNaming Linguistics Antipattern - The field 'isFullyIgnored' indicates linguistically it is a boolean, but it is 'IsFullyIgnored' 3 22
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 3 34

civitas.common - civitas/result/CompareBeats.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 6

civitas.common - civitas/result/ComputeWinners.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 10
UseVarargs Consider using varargs for methods or constructors which take an array the last parameter. 4 15

civitas.common - civitas/result/FormatResult.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 9
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 3 15
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 3 17

civitas.common - civitas/result/InitialMatrix.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 6
CompareObjectsWithEquals Use equals() to compare object references. 3 14

civitas.common - civitas/result/IsFullyIgnored.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 6

civitas.common - civitas/result/MakeCloudWordList.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 9
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 3 16

civitas.common - civitas/result/Max.java

Rule Violation Priority Line
ShortClassName Avoid short class names like Max 4 7
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 7

civitas.common - civitas/result/Min.java

Rule Violation Priority Line
ShortClassName Avoid short class names like Min 4 7
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 7

civitas.common - civitas/result/TransitiveClosure.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 7

civitas.common - civitas/util/CivitasBigIntegerDeserializer.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 12

civitas.common - civitas/util/CivitasBigIntegerSerializer.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11

civitas.common - civitas/util/GetReaderForFile.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11

civitas.common - civitas/AppTestConfig.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 12

civitas.common - civitas/WebAppTestConfig.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 13

civitas.common - civitas/bboard/common/VerifyBBPostTest.java

Rule Violation Priority Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 26
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 28

civitas.common - civitas/bboard/server/EndToEndTest.java

Rule Violation Priority Line
ExcessiveImports A high number of imports can indicate a high degree of coupling within an object. 3 1156
SingularField Perhaps 'keys' could be replaced by a local variable. 3 82
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 105
LinguisticNaming Linguistics Antipattern - The getter 'getTestKeys' should not return void linguistically 3 139
DetachedTestCase Probable detached JUnit test case. 3 139

civitas.common - civitas/bboard/server/controllers/CloseBoardControllerTest.java

Rule Violation Priority Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 37
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 44
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 44
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 46
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 46
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 53
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 98

civitas.common - civitas/bboard/server/controllers/EnvDependentAnswer.java

Rule Violation Priority Line
ClassesShouldBeKnown Classes should be either Data, Service,Controller,Repository 3 11
AvoidFieldNameMatchingMethodName Field answer has the same name as a method 3 13

civitas.common - civitas/bboard/server/controllers/PostControllerTest.java

Rule Violation Priority Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 40
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 55
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 102

civitas.common - civitas/common/ballotdesign/DecomposeBallotTest.java

Rule Violation Priority Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 35

civitas.common - civitas/common/ballotdesign/GetIndexOfCandidateTest.java

Rule Violation Priority Line
UseLocaleWithCaseConversions When doing a String.toLowerCase()/toUpperCase() call, use a Locale 3 26

civitas.common - civitas/common/capabilityencryption/EncryptCapabilityStub.java

Rule Violation Priority Line
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 3 1516

civitas.common - civitas/common/capabilityencryption/EncryptCapabilityTest.java

Rule Violation Priority Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 26

civitas.common - civitas/common/election/IsVoterSubmissionInBlockTest.java

Rule Violation Priority Line
TooManyMethods This class has too many methods, consider refactoring it. 3 2199
LinguisticNaming Linguistics Antipattern - The field 'isVoterSubmissionInBlock' indicates linguistically it is a boolean, but it is 'IsVoterSubmissionInBlock' 3 24
AvoidDuplicateLiterals The String literal "(version with context)" appears 4 times in this file; the first occurrence is on line 47 3 47
AvoidDuplicateLiterals The String literal "(version with encrypted capabilities)" appears 4 times in this file; the first occurrence is on line 74 3 74

civitas.common - civitas/common/encryptedchoice/EncryptChoiceStub.java

Rule Violation Priority Line
AvoidInstantiatingObjectsInLoops Avoid instantiating new objects inside loops 3 1719

civitas.common - civitas/common/encryptedchoice/EncryptChoiceTest.java

Rule Violation Priority Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 28

civitas.common - civitas/common/mix/capabilitymix/AddCommitmentToMixTest.java

Rule Violation Priority Line
RelianceOnDefaultCharset Specify a character set instead of relying on the default charset 3 20

civitas.common - civitas/common/mix/revelation/VerifyMixRevelationTest.java

Rule Violation Priority Line
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 3 37
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 3 49
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 3 62
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 3 74
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 3 86
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 3 98
UnitTestShouldIncludeAssert This unit test should include assert() or fail() 3 110

civitas.common - civitas/common/mix/voteelementrevelation/VerifyMixVoteElementRevelationTest.java

Rule Violation Priority Line
TooManyMethods This class has too many methods, consider refactoring it. 3 17112

civitas.common - civitas/common/mix/votemix/AddVoteAndCommitmentToVoteMixTest.java

Rule Violation Priority Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 20

civitas.common - civitas/common/votercapabilitysharesandproofs/VerifyVoterCapabilitySharesAndProofTest.java

Rule Violation Priority Line
TooManyMethods This class has too many methods, consider refactoring it. 3 16182

civitas.common - civitas/functionaltests/CreatePermutationFunctionalTest.java

Rule Violation Priority Line
AvoidFieldNameMatchingMethodName Field createPermutation has the same name as a method 3 28
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 32
LinguisticNaming Linguistics Antipattern - The variable 'hasIt' indicates linguistically it is a boolean, but it is 'boolean[]' 3 35
UnnecessaryBooleanAssertion assertTrue(true) or similar statements are unnecessary 3 45

civitas.common - civitas/functionaltests/GenerateSafePrimeFunctionalTest.java

Rule Violation Priority Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 38

civitas.common - civitas/functionaltests/GenerateSchnorrPrimeFunctionalTest.java

Rule Violation Priority Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 32

civitas.common - civitas/result/ComputeWinnersFunctionalTest.java

Rule Violation Priority Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 45

civitas.common - civitas/util/ObtainProbablePrimeFunctionalTest.java

Rule Violation Priority Line
UnitTestContainsTooManyAsserts Unit tests should not contain more than 1 assert(s). 3 29