Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 7 of 7 for test_execute_withException (0.35 sec)

  1. src/test/java/org/codelibs/fess/job/UpdateLabelJobTest.java

            assertTrue(result.contains("3 docs"));
            // queryBuilder field is protected, so we can't directly assert it
        }
    
        // Test execute() method with exception handling
        public void test_execute_withException() {
            // Register a mock that throws exception
            SearchEngineClient exceptionClient = new SearchEngineClient() {
                @Override
                public long updateByQuery(String index,
    Registered: Thu Sep 04 12:52:25 UTC 2025
    - Last Modified: Tue Aug 19 14:09:36 UTC 2025
    - 9.4K bytes
    - Viewed (0)
  2. src/test/java/org/codelibs/fess/job/AggregateLogJobTest.java

            String result = aggregateLogJob.execute();
    
            // Verify result is empty string on success
            assertNotNull(result);
            assertEquals("", result);
        }
    
        public void test_execute_withException() {
            // Setup mock SearchLogHelper that throws exception
            final String errorMessage = "Test exception occurred";
            SearchLogHelper mockSearchLogHelper = new SearchLogHelper() {
                @Override
    Registered: Thu Sep 04 12:52:25 UTC 2025
    - Last Modified: Tue Aug 19 14:09:36 UTC 2025
    - 12.1K bytes
    - Viewed (0)
  3. src/test/java/org/codelibs/fess/job/PurgeDocJobTest.java

            assertEquals("now", rangeQuery.to());
    
            // Assert result is empty when successful
            assertEquals("", result);
        }
    
        public void test_execute_withException() {
            // Create mock SearchEngineClient that throws exception
            searchEngineClient = new SearchEngineClient() {
                @Override
    Registered: Thu Sep 04 12:52:25 UTC 2025
    - Last Modified: Tue Aug 19 14:09:36 UTC 2025
    - 16.1K bytes
    - Viewed (0)
  4. src/test/java/org/codelibs/fess/score/ScoreUpdaterTest.java

            assertTrue(result.contains("TestScoreBooster : 100"));
            assertTrue(result.contains("TestScoreBooster : 200"));
        }
    
        // Test execute with exception in booster
        public void test_execute_withException() {
            TestScoreBooster booster1 = new TestScoreBooster(100L);
            ExceptionScoreBooster booster2 = new ExceptionScoreBooster();
            TestScoreBooster booster3 = new TestScoreBooster(300L);
    
    Registered: Thu Sep 04 12:52:25 UTC 2025
    - Last Modified: Tue Aug 19 14:09:36 UTC 2025
    - 10.3K bytes
    - Viewed (0)
  5. src/test/java/org/codelibs/fess/job/PythonJobTest.java

                    assertTrue(e.getCause().getMessage().contains("Process start failed"));
                }
            }
        }
    
        // Test execute with exception handling
        public void test_execute_withException() {
            pythonJob.filename("test.py");
    
            testProcessHelper.throwException = new RuntimeException("Unexpected error");
    
            String result = pythonJob.execute();
    
    Registered: Thu Sep 04 12:52:25 UTC 2025
    - Last Modified: Tue Aug 19 14:09:36 UTC 2025
    - 22.1K bytes
    - Viewed (0)
  6. src/test/java/org/codelibs/fess/job/GenerateThumbnailJobTest.java

            assertNotNull(thumbnailJob.sessionId);
            assertTrue(result.contains("Session Id: " + thumbnailJob.sessionId));
        }
    
        // Test execute with exception
        public void test_execute_withException() {
            thumbnailJob.numOfThreads(2);
    
            testProcessHelper.throwException = new RuntimeException("Unexpected error");
    
            String result = thumbnailJob.execute();
    
    Registered: Thu Sep 04 12:52:25 UTC 2025
    - Last Modified: Tue Aug 19 14:09:36 UTC 2025
    - 18.8K bytes
    - Viewed (0)
  7. src/test/java/org/codelibs/fess/job/ExecJobTest.java

            // Test with minimum timeout
            execJob.timeout(Integer.MIN_VALUE);
            assertEquals(Integer.MIN_VALUE, execJob.timeout);
        }
    
        // Test exception handling in execute
        public void test_execute_withException() {
            execJob.setThrowException(true);
    
            try {
                execJob.execute();
                fail("Should throw RuntimeException");
            } catch (RuntimeException e) {
    Registered: Thu Sep 04 12:52:25 UTC 2025
    - Last Modified: Tue Aug 19 14:09:36 UTC 2025
    - 24.5K bytes
    - Viewed (0)
Back to top