code: def test_detail_prof_init_and_url_non_studio_user(mock_file_exists):
      """
      Test DetailProfilerApp for non Studio users.
      """
      mock_file_exists.return_value = False
      detail_profiler_app = DetailProfilerApp(TEST_REGION)
      assert detail_profiler_app.region == TEST_REGION
      assert detail_profiler_app._domain_id is None
      assert detail_profiler_app._user_profile_name is None
      assert detail_profiler_app._valid_domain_and_user is False
  
      # test url without job redirect
      assert (
          detail_profiler_app.get_app_url()
          == BASE_URL_NON_STUDIO_FORMAT.format(region=TEST_REGION)
      )
  
      # test url with valid job redirect
      assert detail_profiler_app.get_app_url(
          TEST_TRAINING_JOB
      ) == BASE_URL_NON_STUDIO_FORMAT.format(region=TEST_REGION)
  
file_path: sagemaker-python-sdk/tests/unit/test_profiler_app.py
imports: from __future__ import absolute_import
  from sagemaker.interactive_apps.detail_profiler_app import DetailProfilerApp
  from unittest.mock import patch, mock_open, PropertyMock
  import json
  import pytest
label_desc: Use image node_id 1 for calling a global function with example usage: test_detail_prof_init_and_url_non_studio_user(mock_file_exists) without return types