This is the idea I've got in the back of my mind to allow for easier testing of service(8), maybe sysrc(8) if that makes sense as well.
Allow override of local rc.conf with an environment variable, in similar fashion to __MAKE_CONF: __RC_CONF. This allows the environment to override the sourcing of /etc/rc.conf and /etc/rc.conf.local for reasonable testing of service(8). An example test being able to create an rc.conf that overrides local_startup and/or other rc vars so that it can reasonably test without worrying about an installed port breaking things.