50 lines
1.4 KiB
Python
50 lines
1.4 KiB
Python
#!/usr/bin/env python3
|
|
"""
|
|
Quick test to verify the enhanced mouse movement behavior
|
|
"""
|
|
|
|
import sys
|
|
import os
|
|
|
|
# Add src directory to path
|
|
sys.path.insert(0, os.path.join(os.path.dirname(os.path.dirname(__file__)), 'src'))
|
|
|
|
from mouse_mover import MouseMover
|
|
from logging_config import setup_logging, get_logger
|
|
import time
|
|
|
|
def quick_test():
|
|
"""Quick test of mouse movement"""
|
|
setup_logging(debug=True)
|
|
logger = get_logger(__name__)
|
|
|
|
print("🧪 Quick Mouse Movement Test")
|
|
print("========================================")
|
|
|
|
# Create mouse mover with very short wait time for testing
|
|
mouse_mover = MouseMover(wait_time=5, move_px=15) # 5 second wait, 15px movement
|
|
|
|
print("Testing enhanced mouse movement...")
|
|
print("Mouse should move automatically every 5 seconds when idle")
|
|
print("This includes: vertical movement, wiggle, and F15 key press")
|
|
print("Watch the console for debug messages...")
|
|
print("")
|
|
|
|
try:
|
|
mouse_mover.start()
|
|
|
|
# Let it run for 30 seconds
|
|
for i in range(30):
|
|
status = mouse_mover.get_status()
|
|
print(f"⏱️ Time: {i}s, Countdown: {status['countdown']}s")
|
|
time.sleep(1)
|
|
|
|
except KeyboardInterrupt:
|
|
print("\n⏹️ Interrupted by user")
|
|
finally:
|
|
mouse_mover.stop()
|
|
print("✅ Test completed!")
|
|
|
|
if __name__ == "__main__":
|
|
quick_test()
|