We'll create fresh WordPress site with Default Attributes for WooCommerce installed. You have 20 minutes to test the plugin after that site we'll be deleted.
WooCommerce plugin that sets default attribute for variable products automatically if only 1 option is in-stock.
Variable product of T-shirt with color attribute (White/Blue/Black) and size attribute (S/M/XL):
If only Black T-shirts are in-stock: default color (Black), default size (none).
If only Small T-shirts are in-stock: default color (none), default size (Small).
If only White and XL T-shirts are in-stock: default color (White), default size (XL).