def METHOD_NAME(name, expected):
    """Test WorkspaceConfig."""
    test_config1 = get_test_data_path().parent.joinpath("msticpyconfig-test.yaml")
    with custom_mp_config(test_config1):
        # Named workspace
        wstest_config = WorkspaceConfig(workspace=name)
        check.is_in("workspace_id", wstest_config)
        check.equal(wstest_config["workspace_id"], expected.ws_id)
        check.equal(wstest_config["tenant_id"], expected.tenant_id)
        check.equal(wstest_config["workspace_name"], expected.ws_name)
        check.is_not_none(wstest_config.code_connect_str)
        check.is_true(
            wstest_config.code_connect_str.startswith("loganalytics://code().tenant(")
            and expected.ws_id in wstest_config.code_connect_str
            and expected.tenant_id in wstest_config.code_connect_str
        )