This guide provides step-by-step instructions for testing all privacy and security fixes in Lockify.
- Lockify app installed on test device
- At least 2-3 apps added to protected apps list
- Accessibility service enabled
- Test device with Android 8.0+ (recommended: test on multiple Android versions)
- Open Lockify app
- Set a PIN or Pattern lock
- Add test apps to protected list (e.g., Chrome, Gmail, Calculator)
- Enable Accessibility Service
- Enable "Protect Apps" toggle in settings
- Disable "Unlock Time Duration" (set to 0) for strict testing
- Enable/disable biometric auth as needed for specific tests
- Keep logging enabled during testing for debugging
Objective: Verify no content visible before authentication
Steps:
- Ensure protected app is not running
- Tap protected app icon from launcher
- Observe transition carefully
Expected Result:
- Lock screen appears immediately
- No glimpse of app content
- No flicker or flash of protected app
- Smooth transition to lock screen
Pass Criteria: Zero visible content before lock screen
Objective: Verify protection works from app drawer
Steps:
- Open app drawer
- Tap protected app
- Observe transition
Expected Result:
- Lock screen appears immediately
- No content leak
Pass Criteria: Zero visible content before lock screen
Objective: Verify no content visible when minimizing
Steps:
- Open and unlock a protected app
- Press Home button or use gesture to minimize
- Observe the transition
Expected Result:
- Smooth transition to home screen
- No content visible during transition
- App minimizes cleanly
Pass Criteria: No content leak during minimize
Objective: Verify protected app thumbnail is secure
Steps:
- Open and unlock a protected app
- Use app for a few seconds
- Open Recent Apps (square button or swipe up gesture)
- Look at the protected app's thumbnail
Expected Result:
- Protected app thumbnail shows lock screen OR blank screen
- No actual app content visible in thumbnail
- Other unprotected apps show normal thumbnails
Pass Criteria: No app content in recent apps thumbnail
Objective: Verify relock when returning from recents
Steps:
- Open and unlock a protected app
- Press Home button
- Open Recent Apps
- Tap the protected app thumbnail
Expected Result:
- Lock screen appears immediately
- Must re-authenticate
- No content visible before authentication
Pass Criteria: Requires re-authentication, no content leak
Objective: Verify unlock state cleared on app switch
Steps:
- Open and unlock protected app A
- Press Home button
- Open another app (protected or unprotected)
- Return to protected app A
Expected Result:
- Lock screen appears when returning to app A
- Must re-authenticate
Pass Criteria: Requires re-authentication
Objective: Verify no leaks during rapid switching
Steps:
- Open and unlock protected app A
- Quickly switch to protected app B (via recents)
- Quickly switch back to app A
- Repeat several times rapidly
Expected Result:
- Lock screen appears for each protected app
- No content glimpses during fast switching
- No crashes or lag
Pass Criteria: Smooth operation, no content leaks
Objective: Verify each app requires separate authentication
Steps:
- Open and unlock protected app A
- Press Home
- Open protected app B
- Authenticate app B
- Return to app A via recents
Expected Result:
- App B requires authentication
- App A requires re-authentication when returned to
- Each app maintains separate lock state
Pass Criteria: Each app requires separate auth
Objective: Verify unlock state cleared on screen off
Steps:
- Open and unlock a protected app
- Press power button to turn screen off
- Wait 2 seconds
- Press power button to turn screen on
- Unlock device
- Protected app should be visible in foreground
Expected Result:
- Lock screen appears immediately
- Must re-authenticate
- No content visible
Pass Criteria: Requires re-authentication after screen off
Objective: Verify lock screen state preserved
Steps:
- Open protected app (lock screen appears)
- Press power button before authenticating
- Turn screen back on
- Unlock device
Expected Result:
- Lock screen still present
- Can continue authentication
- No content leak
Pass Criteria: Lock screen preserved, no content visible
Objective: Verify no content leak during rotation
Steps:
- Open protected app (lock screen appears)
- Rotate device 90 degrees
- Observe transition
Expected Result:
- Lock screen rotates smoothly
- No glimpse of protected app content
- Authentication state preserved
Pass Criteria: No content leak during rotation
Objective: Verify unlock state preserved during rotation
Steps:
- Open and unlock protected app
- Rotate device
- Use app normally
Expected Result:
- App rotates normally
- Unlock state preserved
- No unexpected relock
Pass Criteria: Smooth rotation, state preserved
Objective: Verify biometric auth works without content leak
Steps:
- Enable biometric authentication in settings
- Open protected app
- Use fingerprint/face to authenticate
Expected Result:
- Biometric prompt appears
- On success, app unlocks smoothly
- No content visible before authentication
Pass Criteria: Smooth biometric auth, no content leak
Objective: Verify fallback to PIN works
Steps:
- Open protected app
- Cancel biometric prompt
- Enter PIN/pattern
Expected Result:
- Can fallback to PIN/pattern
- No content visible
- Lock screen remains secure
Pass Criteria: Fallback works, no content leak
Objective: Verify lock screen cannot be captured
Steps:
- Open protected app (lock screen appears)
- Attempt to take screenshot (Power + Volume Down)
Expected Result:
- Screenshot blocked or shows black screen
- System may show "Can't take screenshot" message
- Lock screen content not captured
Pass Criteria: Screenshot blocked or shows blank
Objective: Verify screen recording protection
Steps:
- Start screen recording
- Open protected app
- Stop recording
- View recording
Expected Result:
- Lock screen appears as black or blank in recording
- Protected app content not visible in recording
- Recording continues but content protected
Pass Criteria: Protected content not in recording
Objective: Verify grace period works correctly
Steps:
- Set unlock duration to 1 minute in settings
- Open and unlock protected app
- Press Home immediately
- Reopen app within 5 seconds
Expected Result:
- App opens without requiring re-authentication
- Grace period working as intended
Pass Criteria: No re-auth within grace period
Objective: Verify relock after grace period expires
Steps:
- Set unlock duration to 1 minute
- Open and unlock protected app
- Press Home
- Wait 2 minutes
- Reopen app
Expected Result:
- Lock screen appears
- Must re-authenticate
- Grace period expired correctly
Pass Criteria: Requires re-auth after grace period
Objective: Verify stability under stress
Steps:
- Rapidly open and close protected app 10 times
- Authenticate each time
Expected Result:
- No crashes
- Lock screen appears each time
- Smooth operation
Pass Criteria: Stable operation, no crashes
Objective: Verify protection after process death
Steps:
- Open and unlock protected app
- Open many other apps to trigger low memory
- Return to protected app
Expected Result:
- Lock screen appears if app was killed
- No content visible
- Protection restored after process recreation
Pass Criteria: Protection works after process death
Objective: Verify notifications don't bypass lock
Steps:
- Ensure protected app is locked
- Receive notification from protected app
- Tap notification
Expected Result:
- Lock screen appears
- Must authenticate before accessing app
- Notification doesn't bypass lock
Pass Criteria: Lock screen appears, no bypass
Objective: Verify anti-uninstall protection
Steps:
- Enable anti-uninstall for a protected app
- Long-press app icon
- Attempt to uninstall
Expected Result:
- Uninstall blocked or requires authentication
- No content leak during uninstall flow
- Protection maintained
Pass Criteria: Uninstall protected, no content leak
Objective: Verify lock screen appears quickly
Steps:
- Open protected app
- Measure time to lock screen appearance
Expected Result:
- Lock screen appears within 200-500ms
- No visible delay
- Smooth transition
Pass Criteria: Fast appearance, smooth UX
Objective: Verify minimal battery drain
Steps:
- Use device normally for 1 hour with Lockify enabled
- Check battery usage in settings
Expected Result:
- Lockify uses minimal battery (<2% per hour)
- No excessive background activity
- Efficient operation
Pass Criteria: Low battery usage
After any code changes, run this quick regression suite:
- ✅ Launch protected app from launcher - no content leak
- ✅ View recent apps - no content in thumbnail
- ✅ Reopen from recents - requires re-auth
- ✅ Screen off/on - requires re-auth
- ✅ Rotate device - no content leak
- ✅ Fast app switching - no content leak
- ✅ Screenshot attempt - blocked
- ✅ Multiple protected apps - each requires auth
Test Date: [DATE]
Device: [DEVICE MODEL]
Android Version: [VERSION]
Lockify Version: [VERSION]
Test Results:
- Protected App Launch: PASS/FAIL
- Recent Apps Privacy: PASS/FAIL
- App Switching: PASS/FAIL
- Screen Lock: PASS/FAIL
- Configuration Changes: PASS/FAIL
- Biometric Auth: PASS/FAIL
- Screenshot Protection: PASS/FAIL
- Grace Period: PASS/FAIL
- Edge Cases: PASS/FAIL
- Performance: PASS/FAIL
Issues Found:
[List any issues]
Notes:
[Additional observations]
For CI/CD integration, consider:
- UI Automator tests for launch scenarios
- Espresso tests for lock screen UI
- Screenshot comparison tests
- Performance benchmarks
- Memory leak detection
This comprehensive test suite ensures Lockify provides:
- Zero content leakage
- Zero preview leaks
- Zero state leaks
- Production-ready privacy
- Smooth performance
Run all tests before each release to maintain privacy and security standards.