update broadcast function and tests