Skip to content

Commit

Permalink
test: 캐스퍼 봇 응모 여부
Browse files Browse the repository at this point in the history
  • Loading branch information
k000927 committed Jul 31, 2024
1 parent 054aee5 commit eab1748
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
name: Deploy to EC2 with Docker Compose

on:
pull_request:
push:
branches:
- dev
- test/db

env:
AWS_REGION: ap-northeast-2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,10 @@ public ResponseEntity<CustomResponse<GetCasperBot>> postCasperBot(@CookieValue S
@RequestBody String body) {
return new ResponseEntity<>(CustomResponse.create(lotteryEventService.postCasperBot(userData, body)), HttpStatus.CREATED);
}

@GetMapping("/{casperBotId}")
public ResponseEntity<GetCasperBot> getCasperBot(@PathVariable String casperBotId){
return new ResponseEntity<>(lotteryEventService.getCasperBot(Long.parseLong(casperBotId)), HttpStatus.OK);
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -54,4 +54,9 @@ public LotteryParticipants registerUserIfNeed(String userData) {

return participants;
}

public GetCasperBot getCasperBot(long casperBotId){
return GetCasperBot.of(casperBotRepository.findById(casperBotId).get());
}

}

0 comments on commit eab1748

Please sign in to comment.