dnsmasq in ubuntu zesty
The systemd included in ubuntu zesty doesn't work nicely with dnsmasq by default, which is a pain if you are a developer and want to setup a local .test or similar domain. The way around this is to change the /etc/systemd/resolved.conf and uncomment/add a line like:
DNSStubListener=no
Then setup you dnsmasq as normal, probably by creating a file /etc/dnsmasq.d/test with the contents: