File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
opengrok-web/src/test/java/org/opengrok/web/api/v1/controller Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -393,8 +393,8 @@ void testIndexed() throws IOException {
393
393
// Test that the project's indexed flag becomes true only after
394
394
// the message is applied.
395
395
396
- markIndexed (projectName );
397
396
397
+ assertEquals (markIndexed (projectName ).getStatusInfo ().getFamily (), Response .Status .Family .SUCCESSFUL );
398
398
assertTrue (env .getProjects ().get (projectName ).isIndexed (), "indexed flag should be set to true" );
399
399
400
400
// Test that the "indexed" message triggers refresh of current version
@@ -406,18 +406,19 @@ void testIndexed() throws IOException {
406
406
assertTrue (ri .getCurrentVersion ().contains ("c78fa757c524" ), "current version should be refreshed" );
407
407
}
408
408
409
- private void markIndexed (final String project ) {
410
- target ("projects" )
409
+ private Response markIndexed (final String project ) {
410
+ Response response = target ("projects" )
411
411
.path (project )
412
412
.path ("indexed" )
413
413
.request ()
414
414
.put (Entity .text ("" ));
415
+ return waitForTask (response );
415
416
}
416
417
417
418
@ Test
418
419
void testList () {
419
420
addProject ("mercurial" );
420
- markIndexed ("mercurial" );
421
+ assertEquals ( markIndexed ("mercurial" ). getStatusInfo (). getFamily (), Response . Status . Family . SUCCESSFUL );
421
422
422
423
// Add another project.
423
424
addProject ("git" );
You can’t perform that action at this time.
0 commit comments