Set testmode in construct based on debug config