@Test
  public void testSetGlobalUserSettingNonAdmin() throws Exception {
    final String settingName = "settingName";
    final String settingValue = "settingValue";

    when(securityHelper.isPentahoAdministrator(eq(session))).thenReturn(false);

    assertEquals(4, globalSettings.size());
    userSettingService.setGlobalUserSetting(settingName, settingValue);
    assertEquals(4, globalSettings.size());
  }
  @Test
  public void testSetGlobalUserSettingAdmin() throws Exception {
    final String settingName = "settingName";
    final String settingValue = "settingValue";

    when(securityHelper.isPentahoAdministrator(eq(session))).thenReturn(true);

    assertEquals(4, globalSettings.size());
    userSettingService.setGlobalUserSetting(settingName, settingValue);
    assertEquals(5, globalSettings.size());

    verify(repository).setFileMetadata(eq(TENANT_FOLDER_ID), anyMap());
  }