[generic] Modernize tests