Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ICTL-851 Add support for JUnit 5 for LLM-based test generation #118

Merged
merged 37 commits into from
Feb 21, 2024
Merged
Changes from 1 commit
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
3134a4c
feat: add junit selection
NikolaiSviridov Feb 9, 2024
445436e
remove: import
NikolaiSviridov Feb 12, 2024
d2abd82
feat: extract JUnitVersion
NikolaiSviridov Feb 13, 2024
c0fbcec
feat: extract JUnitCombobox
NikolaiSviridov Feb 13, 2024
a6ef00d
fix: add JUnit5 dependency
NikolaiSviridov Feb 13, 2024
56dc970
fix: add JUnit5 dependency
NikolaiSviridov Feb 13, 2024
58b6dd5
cleanup: ktlint
NikolaiSviridov Feb 13, 2024
78b6f75
cleanup
NikolaiSviridov Feb 13, 2024
42242ae
feat: remove prints in SingleJUnitTestRunner5
NikolaiSviridov Feb 13, 2024
b09077d
feat: add JUnit5 @ExtendWith in TestAssembler, extract regex logic to…
NikolaiSviridov Feb 13, 2024
45a0f55
cleanup: ktlint
NikolaiSviridov Feb 13, 2024
72fcaed
Create a module template and include it in root settings gradle
Vladislav0Art Feb 16, 2024
a3b85c2
Move prompt generation and psi utils into separate module named core
Vladislav0Art Feb 16, 2024
79c723e
Apply formatting to created files
Vladislav0Art Feb 16, 2024
c12f2db
Remove whitespaces
Vladislav0Art Feb 16, 2024
731e2cd
Update import of a function in tests
Vladislav0Art Feb 16, 2024
719cb6b
Revert "Update import of a function in tests"
Vladislav0Art Feb 19, 2024
998f6f0
Revert "Remove whitespaces"
Vladislav0Art Feb 19, 2024
a992328
Revert "Apply formatting to created files"
Vladislav0Art Feb 19, 2024
330ecfb
Revert "Move prompt generation and psi utils into separate module nam…
Vladislav0Art Feb 19, 2024
c53387b
Add core module as a dependency for root project
Vladislav0Art Feb 19, 2024
e115e54
Move prompt generation functionaltiy (without psi) into separate modu…
Vladislav0Art Feb 19, 2024
2d956c3
Move variables creation and read operations into Application.runReadA…
Vladislav0Art Feb 19, 2024
a9b0e76
Move polymorphism relations into context and remove from generating m…
Vladislav0Art Feb 19, 2024
3ed050f
Add checks for internal java methods
Vladislav0Art Feb 19, 2024
f16ab6c
Move prompt modifications into PromptBuilder
Vladislav0Art Feb 19, 2024
70d0aa2
Apply klint
Vladislav0Art Feb 20, 2024
e67a2a4
Make prompt be modified inside PromptBuilder
Vladislav0Art Feb 20, 2024
90b8d70
Remove commented code
Vladislav0Art Feb 20, 2024
da1b1b5
Add comments to the create components related to prompt generation & …
Vladislav0Art Feb 20, 2024
19ce776
Apply ktlinter and remove wildcard import
Vladislav0Art Feb 20, 2024
c216f24
fix: junit5 runner, test running libs, preselect detected junit
NikolaiSviridov Feb 19, 2024
96e34e2
cleanup: ktlint
NikolaiSviridov Feb 20, 2024
c3692e7
Update SingleJUnitTestRunner5 to print exception same as SingleJUnitT…
pderakhshanfar Feb 20, 2024
476b387
Merge branch 'vartiukhov/enchancement/prompt-generation-separation-in…
pderakhshanfar Feb 20, 2024
c215943
Remove unused imports from PromptManager
pderakhshanfar Feb 20, 2024
b826b74
Remove unused pattern
pderakhshanfar Feb 20, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Revert "Update import of a function in tests"
This reverts commit 731e2cd.
Vladislav0Art committed Feb 19, 2024
commit 719cb6beda4000cce4ca8301dadfaca7a10dbae4
Original file line number Diff line number Diff line change
@@ -2,19 +2,16 @@ package org.jetbrains.research.testspark.helpers

import com.intellij.psi.impl.PsiJavaParserFacadeImpl
import org.assertj.core.api.Assertions.assertThat
import org.jetbrains.research.testspark.core.helpers.generateFieldType
import org.junit.jupiter.params.ParameterizedTest
import org.junit.jupiter.params.provider.Arguments
import org.junit.jupiter.params.provider.MethodSource
import java.util.stream.Stream

class MethodDescriptorHelperTest {

@ParameterizedTest
@MethodSource("primitiveFieldTypeTestGenerator")
fun primitiveFieldTypeTest(
text: String,
expected: String,
) {
fun primitiveFieldTypeTest(text: String, expected: String) {
val psiType = PsiJavaParserFacadeImpl.getPrimitiveType(text)
assertThat(generateFieldType(psiType)).isEqualTo(expected)
}