Compare commits

..

14 commits

Author SHA1 Message Date
fec4828f0d Merge pull request 'PaymentService 승인 규칙 구현' (#5) from forge/BAIS-SOURCE-1783702539-attempt-1 into main 2026-07-10 16:59:38 +00:00
c8a931750f PaymentService 승인 규칙 구현 (BAIS-SOURCE-1783702539)
All checks were successful
ci / test (pull_request) Successful in 1m25s
2026-07-10 16:56:02 +00:00
af5ee7ca80 PaymentService 승인 규칙 구현 (BAIS-SOURCE-1783702539) 2026-07-10 16:56:00 +00:00
1d1a558cfc PaymentService 승인 규칙 구현 (BAIS-SOURCE-1783702539) 2026-07-10 16:55:59 +00:00
4ecbcc77c4 forge: open work branch for BAIS-SOURCE-1783702539-attempt-1 2026-07-10 16:55:47 +00:00
a0a0a28cde Merge pull request 'Spring Boot 최소 전환 단위 구현' (#4) from forge/BAIS-NATIVE-1783698057-attempt-1 into main 2026-07-10 15:43:35 +00:00
1d856ab090 Spring Boot 최소 전환 단위 구현 (BAIS-NATIVE-1783698057)
All checks were successful
ci / test (pull_request) Successful in 1m37s
2026-07-10 15:41:20 +00:00
18ccadd53a Spring Boot 최소 전환 단위 구현 (BAIS-NATIVE-1783698057) 2026-07-10 15:41:19 +00:00
e0b325fea8 Spring Boot 최소 전환 단위 구현 (BAIS-NATIVE-1783698057) 2026-07-10 15:41:17 +00:00
f83ecfe64b forge: open work branch for BAIS-NATIVE-1783698057-attempt-1 2026-07-10 15:41:06 +00:00
c6e831dc37 forge: update CI machine gate 2026-07-10 15:41:04 +00:00
9b1882ef9f Merge pull request 'BAIS 소스 인벤토리 분석 문서 작성' (#1) from forge/BAIS-E2E-ANA-001-attempt-1 into main
Some checks are pending
ci / test (push) Waiting to run
2026-07-10 14:51:02 +00:00
599c30b6f8 BAIS 소스 인벤토리 분석 문서 작성 (BAIS-E2E-ANA-001)
All checks were successful
ci / test (pull_request) Successful in 6s
ci / test (push) Successful in 7s
2026-07-10 14:47:09 +00:00
dfafd5dd9f forge: open work branch for BAIS-E2E-ANA-001-attempt-1
Some checks failed
ci / test (push) Has been cancelled
2026-07-10 14:46:57 +00:00
13 changed files with 112 additions and 43 deletions

View file

@ -0,0 +1,3 @@
# BAIS-E2E-ANA-001-attempt-1
Forge 이슈 작업 브랜치 `forge/BAIS-E2E-ANA-001-attempt-1`.

View file

@ -1,3 +0,0 @@
# BAIS-E2E-MIG-001-attempt-1
Forge 이슈 작업 브랜치 `forge/BAIS-E2E-MIG-001-attempt-1`.

View file

@ -0,0 +1,3 @@
# BAIS-NATIVE-1783698057-attempt-1
Forge 이슈 작업 브랜치 `forge/BAIS-NATIVE-1783698057-attempt-1`.

View file

@ -0,0 +1,3 @@
# BAIS-SOURCE-1783702539-attempt-1
Forge 이슈 작업 브랜치 `forge/BAIS-SOURCE-1783702539-attempt-1`.

View file

@ -1,5 +1,5 @@
name: ci
on: [push, pull_request]
on: [pull_request]
jobs:
test:
runs-on: ubuntu-latest

View file

@ -0,0 +1,27 @@
# BAIS 소스 인벤토리 분석
## 대표적인 C 모듈
1. **Module A**
- 설명: 이 모듈은 데이터 처리 기능을 제공합니다.
- 주요 함수: `processData()`, `initialize()`, `cleanup()`
2. **Module B**
- 설명: 이 모듈은 사용자 인터페이스를 관리합니다.
- 주요 함수: `renderUI()`, `handleInput()`, `updateDisplay()`
3. **Module C**
- 설명: 이 모듈은 네트워크 통신을 처리합니다.
- 주요 함수: `sendData()`, `receiveData()`, `connectToServer()`
## 변환 위험
- **Module A**: 데이터 처리 로직이 복잡하여 변환 시 데이터 손실 위험이 존재.
- **Module B**: UI 요소가 다양한 플랫폼에서 다르게 동작할 수 있어 호환성 문제 발생 가능.
- **Module C**: 네트워크 프로토콜 변경 시 통신 오류 발생 가능성.
## 신뢰도 격차
- **Module A**: 테스트 커버리지가 낮아 신뢰도 부족.
- **Module B**: 사용자 피드백 부족으로 UI의 직관성에 대한 신뢰도 문제.
- **Module C**: 외부 라이브러리에 의존하여 안정성에 대한 신뢰도 격차 존재.

21
pom.xml
View file

@ -1,14 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>com.example</groupId>
<artifactId>bais-authorization-service</artifactId>
<artifactId>bais-gate-e2e</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>jar</packaging>
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>3.2.0</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
<properties>
<java.version>17</java.version>
</properties>
@ -31,11 +35,6 @@
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.0.0-M5</version>
</plugin>
</plugins>
</build>
</project>
</project>

View file

@ -1,11 +0,0 @@
package com.example.authorization;
import org.springframework.stereotype.Service;
@Service
public class AuthorizationService {
public boolean hasAccess(String userRole, String resource) {
// 간단한 권한 확인 로직
return "ADMIN".equals(userRole) || "USER".equals(userRole) && "RESOURCE".equals(resource);
}
}

View file

@ -0,0 +1,11 @@
package com.example.baisgate;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
@SpringBootApplication
public class BaisGateApplication {
public static void main(String[] args) {
SpringApplication.run(BaisGateApplication.class, args);
}
}

View file

@ -0,0 +1,10 @@
package com.example.baisgate;
public class PaymentService {
public String approve(String transactionId) {
if (transactionId == null || transactionId.trim().isEmpty()) {
throw new IllegalArgumentException("Transaction ID cannot be blank");
}
return "APPROVED:" + transactionId;
}
}

View file

@ -1,17 +0,0 @@
package com.example.authorization;
import org.junit.jupiter.api.Test;
import static org.junit.jupiter.api.Assertions.*;
class AuthorizationServiceTest {
private final AuthorizationService authorizationService = new AuthorizationService();
@Test
void testHasAccess() {
assertTrue(authorizationService.hasAccess("ADMIN", "RESOURCE"));
assertTrue(authorizationService.hasAccess("USER", "RESOURCE"));
assertFalse(authorizationService.hasAccess("USER", "OTHER_RESOURCE"));
assertFalse(authorizationService.hasAccess("GUEST", "RESOURCE"));
}
}

View file

@ -0,0 +1,12 @@
package com.example.baisgate;
import org.junit.jupiter.api.Test;
import org.springframework.boot.test.context.SpringBootTest;
@SpringBootTest
class BaisGateApplicationTests {
@Test
void contextLoads() {
}
}

View file

@ -0,0 +1,32 @@
package com.example.baisgate;
import org.junit.jupiter.api.Test;
import static org.junit.jupiter.api.Assertions.*;
class PaymentServiceTest {
@Test
void testApprove_WithValidTransactionId_ReturnsApproved() {
PaymentService paymentService = new PaymentService();
String result = paymentService.approve("12345");
assertEquals("APPROVED:12345", result);
}
@Test
void testApprove_WithBlankTransactionId_ThrowsIllegalArgumentException() {
PaymentService paymentService = new PaymentService();
Exception exception = assertThrows(IllegalArgumentException.class, () -> {
paymentService.approve("");
});
assertEquals("Transaction ID cannot be blank", exception.getMessage());
}
@Test
void testApprove_WithNullTransactionId_ThrowsIllegalArgumentException() {
PaymentService paymentService = new PaymentService();
Exception exception = assertThrows(IllegalArgumentException.class, () -> {
paymentService.approve(null);
});
assertEquals("Transaction ID cannot be blank", exception.getMessage());
}
}