Would be good to remove the 'id' of both User and Role schemas from what is dumped in REST API endpoints. ID of User and Role table are sensitive data that would be fine to hide from the endpoints

tests/api_connexion/endpoints/test_user_endpoint.py
#
#
import pytest
from flask_appbuilder.security.sqla.models import User
from parameterized import parameterized
from airflow.api_connexion.exceptions import EXCEPTIONS_LINK_MAP
from airflow.security import permissions
from airflow.utils import timezone
from tests.test_utils.api_connexion_utils import assert_401, create_user, delete_user
from tests.test_utils.config import conf_vars
DEFAULT_TIME = "2020-06-11T18:00:00+00:00"
@pytest.fixture(scope="module")
def configured_app(minimal_app_for_api):
    app = minimal_app_for_api
    create_user(
        app,  
        username="test",
        role_name="Test",
        permissions=[
            (permissions.ACTION_CAN_LIST, permissions.RESOURCE_USER_DB_MODELVIEW),
            (permissions.ACTION_CAN_SHOW, permissions.RESOURCE_USER_DB_MODELVIEW),
        ],
    )
    create_user(app, username="test_no_permissions", role_name="TestNoPermissions")  
    yield app
    delete_user(app, username="test")  
    delete_user(app, username="test_no_permissions")  
class TestUserEndpoint: