A black woman sued Marks & Spencer after claiming that a secret code name for its diversity programme was racist.