Crab, I disagree if the AP was initiated correctly but a faulty WOG switch prevented the self test from initiating it could then erroneously signal weight on gear at the wrong time and the AP could then initiate the self test at the wrong moment, the self test involving communication with the actuators.
Don't how you think that would happen - if the faulty switch prevented the AP test from running then it would generate a fault code or warning that the self test wasn't complete. If the self test wouldn't initiate then the switch must have failed to an 'airborne' state - how would that now allow the selftest to initiate when the aircraft was light on the skids?