Added spec and fixed an extra verification on trace injection