Class ReviewerComprehensiveTest

java.lang.Object
org.machanism.machai.gw.reviewer.ReviewerComprehensiveTest

class ReviewerComprehensiveTest extends Object
  • Field Details

    • tempDir

      @TempDir Path tempDir
  • Constructor Details

    • ReviewerComprehensiveTest

      ReviewerComprehensiveTest()
  • Method Details

    • htmlReviewer_getSupportedFileExtensions_returnsExpectedExtensions

      @Test void htmlReviewer_getSupportedFileExtensions_returnsExpectedExtensions()
    • htmlReviewer_perform_handlesGuidanceScenarios

      @ParameterizedTest @MethodSource("htmlReviewerScenarios") void htmlReviewer_perform_handlesGuidanceScenarios(String relativePath, String content, boolean expectPrompt) throws IOException
      Throws:
      IOException
    • javaReviewer_getSupportedFileExtensions_returnsExpectedExtensions

      @Test void javaReviewer_getSupportedFileExtensions_returnsExpectedExtensions()
    • javaReviewer_extractPackageName_returnsExpectedValue

      @ParameterizedTest @CsvSource({"\'/* header */\npackage org.example.test;\nclass A {}\', org.example.test","\'package\n org.example.deep.sub;\nclass A {}\', org.example.deep.sub","\'class A {}\', <default package>","\'package 123.invalid;\nclass A {}\', <default package>"}) void javaReviewer_extractPackageName_returnsExpectedValue(String content, String expected)
    • javaReviewer_perform_handlesGuidanceScenarios

      @ParameterizedTest @MethodSource("javaGuidanceFiles") void javaReviewer_perform_handlesGuidanceScenarios(String relativePath, String content, boolean expectPrompt) throws IOException
      Throws:
      IOException
    • javaReviewer_perform_formatsPackageInfoPromptWithoutEmbeddingSourceContent

      @Test void javaReviewer_perform_formatsPackageInfoPromptWithoutEmbeddingSourceContent() throws IOException
      Throws:
      IOException
    • javaReviewer_perform_throwsIOExceptionWhenFileDoesNotExist

      @Test void javaReviewer_perform_throwsIOExceptionWhenFileDoesNotExist()
    • markdownReviewer_getSupportedFileExtensions_returnsExpectedExtensions

      @Test void markdownReviewer_getSupportedFileExtensions_returnsExpectedExtensions()
    • markdownReviewer_perform_handlesGuidanceScenarios

      @ParameterizedTest @MethodSource("markdownGuidanceFiles") void markdownReviewer_perform_handlesGuidanceScenarios(String relativePath, String content, boolean expectPrompt) throws IOException
      Throws:
      IOException
    • pumlReviewer_getSupportedFileExtensions_returnsExpectedExtensions

      @Test void pumlReviewer_getSupportedFileExtensions_returnsExpectedExtensions()
    • pumlReviewer_perform_throwsNullPointerExceptionWhenProjectDirIsNull

      @Test void pumlReviewer_perform_throwsNullPointerExceptionWhenProjectDirIsNull()
    • pumlReviewer_perform_handlesGuidanceScenarios

      @ParameterizedTest @MethodSource("pumlGuidanceFiles") void pumlReviewer_perform_handlesGuidanceScenarios(String relativePath, String content, boolean expectPrompt) throws IOException
      Throws:
      IOException
    • pythonReviewer_getSupportedFileExtensions_returnsExpectedExtensions

      @Test void pythonReviewer_getSupportedFileExtensions_returnsExpectedExtensions()
    • pythonReviewer_perform_handlesGuidanceScenarios

      @ParameterizedTest @MethodSource("pythonGuidanceFiles") void pythonReviewer_perform_handlesGuidanceScenarios(String relativePath, String content, boolean expectPrompt) throws IOException
      Throws:
      IOException
    • textReviewer_getSupportedFileExtensions_returnsExpectedExtensions

      @Test void textReviewer_getSupportedFileExtensions_returnsExpectedExtensions()
    • textReviewer_perform_handlesGuidanceScenarios

      @ParameterizedTest @MethodSource("textReviewerScenarios") void textReviewer_perform_handlesGuidanceScenarios(String relativePath, String content, boolean expectPrompt) throws IOException
      Throws:
      IOException
    • textReviewer_getPrompt_returnsSameReferenceWhenGuidanceIsBlank

      @Test void textReviewer_getPrompt_returnsSameReferenceWhenGuidanceIsBlank()
    • textReviewer_getPrompt_formatsPromptWhenGuidanceIsNotBlank

      @Test void textReviewer_getPrompt_formatsPromptWhenGuidanceIsNotBlank()
    • typeScriptReviewer_getSupportedFileExtensions_returnsExpectedExtensions

      @Test void typeScriptReviewer_getSupportedFileExtensions_returnsExpectedExtensions()
    • typeScriptReviewer_perform_handlesGuidanceScenarios

      @ParameterizedTest @MethodSource("typeScriptGuidanceFiles") void typeScriptReviewer_perform_handlesGuidanceScenarios(String relativePath, String content, boolean expectPrompt) throws IOException
      Throws:
      IOException
    • typeScriptReviewer_perform_throwsIOExceptionWhenFileDoesNotExist

      @Test void typeScriptReviewer_perform_throwsIOExceptionWhenFileDoesNotExist()
    • reviewer_contractCanBeImplementedByCustomType

      @Test void reviewer_contractCanBeImplementedByCustomType() throws IOException
      Throws:
      IOException