mirror of
https://github.com/nsacyber/HIRS.git
synced 2025-04-08 11:54:27 +00:00
Changed the branch naming and addressed a failed unit test. When the
value of the platform version is null, the unit test was failing.
This commit is contained in:
parent
039054b740
commit
300cae3950
@ -1102,6 +1102,9 @@ public class CertificateAttributeScvValidator extends SupplyChainCredentialValid
|
||||
* @return true if they equal Not Specified or Unknown
|
||||
*/
|
||||
public static boolean isNotSpecifiedOrUnknown(final String versionNumber) {
|
||||
if(versionNumber == null) {
|
||||
return true;
|
||||
}
|
||||
String fieldValue = versionNumber.toLowerCase();
|
||||
|
||||
return fieldValue.equals(DeviceInfoEnums.NOT_SPECIFIED.toLowerCase())
|
||||
|
@ -1355,8 +1355,9 @@ public class SupplyChainCredentialValidatorTest {
|
||||
result = CertificateAttributeScvValidator
|
||||
.validatePlatformCredentialAttributesV2p0(platformCredential,
|
||||
deviceInfoReport);
|
||||
assertEquals(AppraisalStatus.Status.FAIL, result.getAppStatus());
|
||||
assertEquals("Platform version did not match\n", result.getMessage());
|
||||
assertEquals(AppraisalStatus.Status.PASS, result.getAppStatus());
|
||||
assertEquals(SupplyChainCredentialValidator.PLATFORM_ATTRIBUTES_VALID,
|
||||
result.getMessage());
|
||||
|
||||
platformCredential = setupMatchingPlatformCredential(deviceInfoReport);
|
||||
result = CertificateAttributeScvValidator
|
||||
|
Loading…
x
Reference in New Issue
Block a user