Test onaddtrack and onremovetrack