To test grid compliances of devices under test (DUT), this paper proposes a passivity-based co-design method for the active damping (AD) and ac voltage controller (VC) used with a converter-based grid emulator. In the approach, a relative passivity depth (RPD) index is introduced to quantify the impact of AD and VC on the impedance passivity. Different from conventional passivity indices, the RPD is independent on the filter plant parameter, and thus enables a more robust co-design of AD and VC. An experimental prototype based on an L-filtered voltage source inverter is tested to validate the effectiveness of proposed method.