Your original way works. configuration["AbpZeroLicenseCode"] returns null because:
Did you run your application?
Well, doesn't the Host DB already exist?
Is there any method to check if a request is coming from an Auhenticated user? Something such as IsUserAuthenticated....?
Why don't you just use the appsettings.json in Test project?
Check error in Logs.txt.
So only the last SetBasePath matters, as it's only used on Build. Why don't you just use the appsettings.json in Test project?
It should be StanchionWebHostModule in your project.