Repository navigation
fix(sample): 예외 처리를 구체화하고 Selenium 테스트를 현행화하다 - #48
Merged
jei007 merged 1 commit intoSep 7, 2026
Merged
Conversation
시큐어코딩 진단 대상인 포괄적 throws Exception 선언을 제거하거나 BaseRuntimeException을 함께 명시한다. FdlException, IOException 및 리플렉션 예외를 BaseRuntimeException으로 변환하고 관련 서비스와 테스트의 예외 선언을 정리한다. Selenium 테스트의 실행 URL, 등록 함수, 확인 대화상자 처리 및 결과 셀렉터를 현재 화면 구조에 맞게 수정한다.
jei007
approved these changes
Sep 7, 2026
jei007
left a comment
Contributor
There was a problem hiding this comment.
표준프레임워크에 대한 지속적인 참여에
대단히 감사드립니다.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
수정 사유 Reason for modification
소스를 수정한 사유가 무엇인지 체크해 주세요. Please check the reason you modified the source. ([X] X는 대문자여야 합니다.)
수정된 소스 내용 Modified source
검토자를 위해 수정된 소스 내용을 설명해 주세요. Please describe the modified source for reviewers.
개요
시큐어코딩 솔루션에서 포괄적인
throws Exception선언이 진단되는 문제를 개선합니다.진단 결과
throws BaseRuntimeException, Exception으로 예외 유형을 명시하면진단되지 않는 것을 확인했으며, 제거할 수 있는 포괄적 예외 선언은 제거하고
필요한 위치에는
BaseRuntimeException을 명시했습니다.아울러 현재 애플리케이션 경로와 화면 구조가 반영되지 않았던 Selenium 테스트를
현행화했습니다.
주요 변경 사항
FdlException을BaseRuntimeException으로 변환IOException을BaseRuntimeException으로 변환BaseRuntimeException으로 변환/egovframe-web으로 변경sampleAdd()로 변경변경 파일
운영 코드
EgovSampleService.javaEgovSampleServiceImpl.javaEgovSampleController.java테스트 코드
EgovErrorViewResourceTest.javaEgovSampleServiceImplTestDeleteSampleTest.javaEgovSampleServiceImplTestInsertSampleTest.javaEgovSampleServiceImplTestUpdateSampleTest.javaSampleMapperTestInsertSampleTest.javaEgovSampleControllerAddSampleRedirectTest.javaEgovSampleControllerTestAddSampleTest.javaEgovSampleListJspPageIndexTest.javaTestEgovSampleControllerTestSelenium.java검증
환경:
결과:
mvn clean test -DskipTests: 성공운영 코드 10개 및 테스트 코드 12개 컴파일 성공
git diff --check: 이상 없음전체 테스트 9개 중 8개 통과
EgovSampleControllerTestAddSampleTest1개는 Jakarta EL 구현이테스트 런타임 클래스패스에 없어 실패하면 Eclipse에서 Maven test 프로파일을 활성화
HV000183: Unable to initialize jakarta.el.ExpressionFactoryEclipse에서 Maven test 프로파일을 활성화하는 설정 화면입니다.

JUnit 테스트 JUnit tests
테스트를 완료하셨으면 다음 항목에 [대문자X]로 표시해 주세요. When you're done testing, check the following items.
테스트 브라우저 Test Browser
테스트를 진행한 브라우저를 선택해 주세요. Please select the browser(s) you ran the test on. (다중 선택 가능 you can select multiple) [X] X는 대문자여야 합니다.
테스트 스크린샷 또는 캡처 영상 Test screenshots or captured video
테스트 전과 후의 스크린샷 또는 캡처 영상을 이곳에 첨부해 주세요. Please attach screenshots or video captures of your before and after tests here.
테스트 후