private void AssertIsMainThread() { if (!_shell.IsUnitTestEnvironment) { _shell.AssertIsOnMainThread(); } }