@Test
  public void manageDataBaseTest() {
    assertNonQueryTestFail(
        "create database root.test2",
        "803: No permissions for this operation, please add privilege MANAGE_DATABASE",
        "test",
        "test123");
    assertNonQueryTestFail(
        "drop database root.test1",
        "803: No permissions for this operation, please add privilege MANAGE_DATABASE",
        "test",
        "test123");

    grantUserSystemPrivileges("test", PrivilegeType.MANAGE_DATABASE);

    executeNonQuery("create database root.test2", "test", "test123");
    executeNonQuery("drop database root.test1, root.test2", "test", "test123");
  }
This Class contains integration tests for SystemPermissions but {@link PrivilegeType#MANAGE_USER}
and {@link PrivilegeType#MANAGE_ROLE}, you can see tests of them in {@link IoTDBAuthIT}.
integration-test/src/test/java/org/apache/iotdb/db/it/auth/IoTDBSystemPermissionIT.java