Posts
Q&A
Could not find or load main class ์๋ฌ ํด๊ฒฐ
plugins { id 'org.springframework.boot' version '2.4.1' id 'io.spring.dependency-management' version '1.0.10.RELEASE' id 'java' } group = 'jpabook' version = '0.0.1-SNAPSHOT' sourceCompatibility = '11' configurations { compileOnly { extendsFrom annotationProcessor } } repositories { mavenCentral() } dependencies { implementation 'org.springframework.boot:spring-boot-starter-data-jpa' implementation 'org.springframework.boot:spring-boot-starter-validation' implementation 'org.springframework.boot:spring-boot-starter-thymeleaf' implementation 'org.springframework.boot:spring-boot-starter-web' compileOnly 'org.projectlombok:lombok' runtimeOnly 'com.h2database:h2' annotationProcessor 'org.projectlombok:lombok' testImplementation 'org.springframework.boot:spring-boot-starter-test' //JUnit4 ์ถ๊ฐ testImplementation("org.junit.vintage:junit-vintage-engine") { exclude group: "org.hamcrest", module: "hamcrest-core" } } test { useJUnitPlatform() }build.gradle ์ ๋๋ค.
- Likes
- 1
- Comments
- 2
- Viewcount
- 15K
Q&A
ํ๋ก๊ทธ๋จ ์์ ๋ฌธ์
๊ฐ์ฌํฉ๋๋ค
- Likes
- 0
- Comments
- 2
- Viewcount
- 808
Q&A
์ํ ๋ฑ๋ก์ค ์ค๋ฅ๊ฐ ๋ฐ์ํฉ๋๋ค
@PostMapping("items/new") public String create(BookForm form) { Book book = new Book(); book.setId(form.getId()); book.setName(form.getName()); book.setPrice(form.getPrice()); book.setStockQuantity(form.getStockQuantity()); book.setAuthor(form.getAuthor()); book.setIsbn(form.getIsbn()); itemService.saveItem(book); return "redirect:/"; redirect ๊ณ ์น๋ฉด ๋ฉ๋๋ค.
- Likes
- 0
- Comments
- 2
- Viewcount
- 554
Q&A
ํน์ ์ ๋ณดํธ๋ก ์ ์ฉ ์๋์๋๋ถ๋ค์
์ ๋ง ๊ฐ์ฌํ๋น๋ค~
- Likes
- 24
- Comments
- 5
- Viewcount
- 1.2K
Q&A
์ํ์ฃผ๋ฌธ ์ฝ๋ ์คํ์ actual์ด ๋ฌ๊ธ์์ด 2๋ก ๋ ์์ด ์ด๋์๋ถํฐ ์๋ชป๋ ๊ฒ์ธ์ง ๋ชจ๋ฅด๊ฒ ์ต๋๋ค.
์ ๋ ๋๊ฐ์ ์๋ฌ ๋ ์ h2 ํ ์ด๋ธ ์ญ์ ํ๊ณ ๋๊ฐ์ด ํ๋๋ฐ ์ค์ ๊ฐ : 10 , ๊ธฐ๋๊ฐ : 8๋ ์ ์ด๋ป๊ฒ ํด์ผํ ์ง ๋ชจ๋ฅด๊ฒ ๋ค์
- Likes
- 0
- Comments
- 8
- Viewcount
- 487
Q&A
org.junit.runners.model.InvalidTestClassError: Invalid test class 'jpabook.jpashop.MemberRepositoryTest' ์๋ฌ...
๊ฐ์ฌํฉ๋๋ค ~~
- Likes
- 0
- Comments
- 2
- Viewcount
- 2.2K
Q&A
fail() ์์ธ๋ฅผ try -catch๋ก ์ก์๋ ์๋ฌ ๋ฐ์
(์ฌ์ง)๋๊น์ง ๋ต๋ณ ์ฃผ์ OMG๋ ๊ฐ์ฌํฉ๋๋ค. ใ ใ ๋๋์ด ๊ณ ์ณค๋ค์. ์๋ฌด๋ฆฌ ๋ด๋ ์ ๊ฐ ์ฝ๋ ์๋ชป์น๊ฑฐ ๊ฐ์์ PDFํ์ผ์ ์๋๊ฑฐ ๋ณต๋ถ ํด๋ดค๋๋ ๊ณ ์ณ์ก์ต๋๋ค. ๊ฐ์ฌํฉ๋๋ค~~ ์ข์ํ๋ฃจ๋ณด๋ด์ธ์
- Likes
- 0
- Comments
- 2
- Viewcount
- 727
Q&A
expected๋ฅผ ์ธ์ํ์ง ๋ชปํฉ๋๋ค
์ ๋ ์์ฑ์๋์ฒ๋ผ ์๋ฌ ๋ฐ์ํด์ import๋ฌธ์ ๋ฐ๊ฟจ์ต๋๋ค ๋ค๋ฅธ๋ถ๋ค ์ฐธ๊ณ ํ์ธ์ (์ฌ์ง)
- Likes
- 0
- Comments
- 3
- Viewcount
- 514




