How to create a seamless environment when writing automation scripts?