You can set a range with settings Login valid after and Login valid before when login is enabled. Here usual scope inheritance does not work. Instead those two settings use MINIMUM (Login valid before) or MAXIMUM (Login valid after) values from higher scopes.
Step 1
Click Security in Configuration menu.
Step 2
Set Login valid after to tomorrow (in format YYYY-MM-DD hh:mm:ss) and click "Save" button.
Step 3
Click testuser1 in User management.
Step 4
Navigate to "Security" tab and set Login valid after for testuser1 to yesterday and click "Save" button.
Step 5
Login with testuser1 - you should get "Login for user "testuser1" is disabled".