The TAB goes to court