Fix random failures in the ListTest and SampleTypeFolderExportImportTest#2550
Merged
labkey-danield merged 4 commits intodevelopfrom Jul 11, 2025
Merged
Fix random failures in the ListTest and SampleTypeFolderExportImportTest#2550labkey-danield merged 4 commits intodevelopfrom
labkey-danield merged 4 commits intodevelopfrom
Conversation
Validate file has been uploaded on the form.
XingY
approved these changes
Jul 10, 2025
labkey-chrisj
approved these changes
Jul 10, 2025
| List<FieldDefinition> testFields = SampleTypeAPIHelper.sampleTypeTestFields(true); | ||
| SampleTypeDefinition testSampleType = new SampleTypeDefinition(testSamples).setFields(testFields) | ||
| .addParentAlias("SelfParent"); // to derive from samles in the current type | ||
| .addParentAlias("SelfParent"); // to derive from samples in the current type |
Contributor
There was a problem hiding this comment.
thanks for fixing that
| // setFormElement doesn't check that the form element is set. | ||
| // Because this test uses random field names, we should validate that the file was actually uploaded. If the | ||
| // file is missing later in the test, we can be sure it was present at this point. | ||
| Assert.assertFalse("File not uploaded.", |
Contributor
There was a problem hiding this comment.
Consider maybe using an awaiting assert here, if file-upload taking a second isn't a failure-worthy situation.
Add a better check that file has been attached.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Rationale
Fixing two test issues. The failure in SampleTypeFolderExportImportTest appears to be random, and may not really need this change, but I think checking is still a good thing to do.
Related Pull Requests
Changes