public static String getUserId() {
        ServletRequestAttributes attributes = (ServletRequestAttributes) RequestContextHolder.getRequestAttributes();
        if (attributes != null) {
            HttpServletRequest request = attributes.getRequest();
            return request.getHeader(CommonConstants.USER_ID_HEADER);
        }
        return "";
    }
@Test
    public void testGetUserIdFromHeaderWhenMissing() {
        // Prepare the scenario where the header is missing
        when(request.getHeader(CommonConstants.USER_ID_HEADER)).thenReturn(null);

        // Call the method under test
        String userId = HeaderUtil.getUserId();

        // Assert that an empty string is returned when the header is missing
        assertNull(userId);
    }