Improve specs with shared examples

Merged Subashis Chakraborty requested to merge 370623-improve-specs into master