Buggy code:
@ ValidationSuite ( name = "Onboarding-v1" ) public class OnboardingTestSuite extends ValidationBaseTestCase { private static final String TAG = "OnboardingTestSuite" ; private static final Logger logger = LoggerFactory . getLogger ( OnboardingTestSuite . TAG ) ; protected static final String INVALID_NETWORK_NAME = "InvalidPersonalAP" ; protected static final String INVALID_NETWORK_PASSPHRASE = "InvalidNetworkPassphrase" ; protected static final short INVALID_AUTH_TYPE = 9999 ; protected static final long TIME_TO_WAIT_FOR_SOFT_AP_IN_MS_SHORT = 120000 ; protected static final long TIME_TO_WAIT_TO_CONNECT_TO_SOFT_AP_IN_MS = 60000 ; protected static final long TIME_TO_WAIT_FOR_SOFT_AP_AFTER_OFFBOARD = 15000 ; protected static final long TIME_TO_WAIT_TO_CONNECT_TO_PERSONAL_AP_IN_MS = 60000 ; protected static final long TIME_TO_WAIT_FOR_DISCONNECT_IN_MS = 30000 ; protected static final long TIME_TO_WAIT_FOR_NEXT_DEVICE_ANNOUNCEMENT_IN_MS = 180000 ; public static final short OBS_STATE_PERSONAL_AP_NOT_CONFIGURED = PERSONAL_AP_NOT_CONFIGURED . getStateId ( ) ; public static final short OBS_STATE_PERSONAL_AP_NOT_VALIDATED = PERSONAL_AP_CONFIGURED_NOT_VALIDATED . getStateId ( ) ; public static final short OBS_STATE_PERSONAL_AP_CONFIGURED_VALIDATED = PERSONAL_AP_CONFIGURED_VALIDATED . getStateId ( ) ; public static final short OBS_STATE_PERSONAL_AP_CONFIGURED_ERROR = PERSONAL_AP_CONFIGURED_ERROR . getStateId ( ) ; public static final short OBS_LASTERROR_VALIDATED = 0 ; public static final short OBS_LASTERROR_UNREACHABLE = 1 ; public static final short OBS_LASTERROR_UNAUTHORIZED = 3 ; protected static final short OBS_CONFIGURE_WIFI_RETURN_NO_CHANNEL_SWITCHING = 1 ; protected static final short OBS_CONFIGURE_WIFI_RETURN_SUPPORTS_CHANNEL_SWITCHING = 2 ; protected static final String ALLJOYN_ERROR_FEATURE_NOT_AVAILABLE = "org.alljoyn.Error.FeatureNotAvailable" ; private ConfigClient configClient ; private AboutClient aboutClient ; private static final char [ ] VALID_DEFAULT_PASSCODE = SrpAnonymousKeyListener . DEFAULT_PINCODE ; private static final char [ ] TEMP_PASSCODE = "111111" . toCharArray ( ) ; private static final char [ ] INVALID_PASSCODE = "123456" . toCharArray ( ) ; protected static final String NEW_DEVICE_NAME = "newDeviceName" ; private OnboardingHelper onboardingHelper ; private WifiNetworkConfig personalAPConfig ; private WifiNetworkConfig softAPConfig ; private static String softAPssid ; private AppUnderTestDetails appUnderTestDetails ; private UUID dutAppId ; private String dutDeviceId ; @ Override public void setUp ( ) throws Exception { } @ Override public void tearDown ( ) throws Exception { } protected OnboardingHelper getOnboardingHelper ( ) { } protected ServiceHelper getServiceHelper ( ) { } protected WifiHelper getWifiHelper ( ) { } @ ValidationTest ( name = "Onboarding-v1-01" , order = - 1 ) public void testOnboarding_v1_01_OffboardDevice ( ) throws Exception { } @ ValidationTest ( name = "Onboarding-v1-02" , order = 99 ) public void testOnboarding_v1_02_OnboardDevice ( ) throws Exception { } @ ValidationTest ( name = "Onboarding-v1-03" ) public void testOnboarding_v1_03_ConnectivityOverSoftAP ( ) throws Exception { } @ ValidationTest ( name = "Onboarding-v1-04" ) @ Disabled public void testOnboarding_v1_04_ConfigureWiFiWithOutOfRangeValue ( ) throws Exception { } @ ValidationTest ( name = "Onboarding-v1-05" ) public void testOnboarding_v1_05_ConfigureWiFiWithWrongSSID ( ) throws Exception { } @ ValidationTest ( name = "Onboarding-v1-06" ) public void testOnboarding_v1_06_ConfigureWiFiWithWrongPassword ( ) throws Exception { connectToDUTInOffboardedState ( ) ; short configureWiFiRetval = onboardingHelper . callConfigureWiFi ( new WifiNetworkConfig ( personalAPConfig . getSsid ( ) , ( "0" + ( personalAPConfig . getPassphrase ( ) ) ) , personalAPConfig . getSecurityType ( ) ) ) ; verifyConfigureWifiReturnValue ( configureWiFiRetval ) ; verifyOnboardingState ( OnboardingTestSuite . OBS_STATE_PERSONAL_AP_NOT_VALIDATED ) ; onboardingHelper . callConnectWiFiAndWaitForSoftAPDisconnect ( ) ; onboardingHelper . connectToDUTOnSoftAP ( ) ; onboardingHelper . waitForAboutAnnouncementAndThenConnect ( ) ; verifyOnboardingState ( OnboardingTestSuite . OBS_STATE_PERSONAL_AP_CONFIGURED_ERROR ) ; <START_BUG> verifyOnboardingErrorCode ( OnboardingTestSuite . OBS_LASTERROR_UNAUTHORIZED ) ; <END_BUG> } @ ValidationTest ( name = "Onboarding-v1-07" ) public void testOnboarding_v1_07_ConfigureWiFiAuthTypeOfAny ( ) throws Exception { } @ ValidationTest ( name = "Onboarding-v1-08" ) public void testOnboarding_v1_08_GetScanInfo ( ) throws Exception { } @ ValidationTest ( name = "Onboarding-v1-09" ) public void testOnboarding_v1_09_WrongPasscode ( ) throws Exception { } @ ValidationTest ( name = "Onboarding-v1-10" ) public void testOnboarding_v1_10_AuthenticateAfterChangingPasscode ( ) throws Exception { } @ ValidationTest ( name = "Onboarding-v1-11" ) public void testOnboarding_v1_11_FactoryResetClearsConfiguration ( ) throws Exception { } @ ValidationTest ( name = "Onboarding-v1-12" ) public void testOnboarding_v1_12_FactoryResetResetsPasscode ( ) throws Exception { } private void placeDUTInOffboardState ( ) throws Exception { } protected String getOnboardeeSoftApSsid ( ) { } protected String getOnboardeeSoftApSecurityType ( ) { } protected String getOnboardeeSoftApPassphrase ( ) { } protected String getPersonalApSsid ( ) { } protected String getPersonalApPassphrase ( ) { } protected short getPersonalApSecurity ( ) { } private void verifyOnboardingState ( short state ) throws BusException { } private void verifyOnboardingErrorCode ( short errorCode ) throws BusException { } private void checkDeviceIsInOnboardedStateAndWaitForAnnouncement ( ) throws Exception { } private void makeSureDeviceIsInOffboardedState ( ) throws Exception { } public AboutAnnouncementDetails placeDUTInOnboardState ( ) throws Exception , BusException { } private AboutAnnouncementDetails connectToDUTInOffboardedState ( ) throws Exception { } private void verifyConfigureWifiReturnValue ( short configureWiFiRetval ) { } private void validateScanResult ( MyScanResult myScanResult ) { } private void validateAuthType ( short authType ) { } private void logBusExceptionInfo ( BusException be ) { } private short getMinAuthTypeId ( ) { } private int getMaxAuthTypeId ( ) { } private void releaseResources ( ) { } private void disconnectConfigClient ( ) { } private void disconnectAboutClient ( ) { } No newline ; at end ; of file ; }

Fix:
assertTrue ( ( ( onboardingHelper . retrieveStateProperty ( ) ) != ( OnboardingTestSuite . OBS_LASTERROR_VALIDATED ) ) ) ;