All or none. Except, anyone who is benefitting must be included. Reminder, if the ONLY reason they are not benefiting is because they fail to meet a condition (like hours or last day), then they can be excluded.
For example, suppose a plan has an hours requirement to get a PS allocation. Employee terminates before meeting the hours requirement, they have under 500 hours, and they get no PS allocation: they can be excluded from the 410(b) test for the PS portion of the plan. All similar employees would have to be treated the same for 410(b).
In contrast, suppose a plan has NO requirements for getting a PS allocation, but they have each person in their own rate group. Employee terminates and the employer allocates $0 to that group. Even if they have under 500 hours and they get no PS allocation: they can NOT excluded from the 410(b) test for the PS portion of the plan. Why? Because the sole reason they are not getting an allocation is NOT because they failed to reach the plan's conditions, instead it's because the employer decided they get zero.
edited to add the cite: treasury regulation 1.410(b)-6(f)(vi): "it is applied with respect to all employees"