Testing complementarity on a transmon quantum processor