1- import { ExperimentCRUDUtils , hookServer , RequestOptions , successfulResponse } from '@labkey/test' ;
1+ import { ExperimentCRUDUtils , hookServer , RequestOptions , selectRandomN , successfulResponse } from '@labkey/test' ;
22import mock from 'mock-fs' ;
33import {
44 checkDomainName ,
@@ -394,6 +394,7 @@ describe('Aliquot crud', () => {
394394 const aliquotQueryCols = 'name, rowid, lsid, description, str, int, isAliquot, AliquotedFromLsid/name, rootmaterialrowid, Myparentcol, Myaliquotcol, Myindependentcol' ;
395395
396396 async function verifyImportingWithNameValue ( parentSampleName : string , sampleType : string ) {
397+ console . log ( 'Selected parentSampleName: ' + parentSampleName ) ;
397398 const parentInsertRow = {
398399 name : parentSampleName ,
399400 description : 'testImportingWithNameValue parent'
@@ -559,14 +560,19 @@ describe('Aliquot crud', () => {
559560 * <li>An aliquot with the name formatted as an aliquot (SAI_1-101).</li>
560561 * <li>And have an aliquot w/o a name set.</li>
561562 * <li>Validate that the names are as expected.</li>
563+ * <li>Issue 53419: Aliquot parent with number like names that starts with leading zeroes aren't resolved during import</li>
562564 * </ul>
563565 * Because importing is batched the imported aliquot without an explicit name set it should have the next
564566 * index (default behavior).
565567 * </p>
566568 */
567- it ( 'testImportingWithNameValue - with naming patten' , async ( ) => {
569+
570+ const parentSampleName = [ 'S-1' , '123' , '0001' , '0002' , 'With Space' , '+ -_.&)(:' ] ;
571+
572+
573+ it ( '(Fuzz Test) testImportingWithNameValue - with naming patten ' , async ( ) => {
568574 // also include scenarios from testImportWithUpdate
569- await verifyImportingWithNameValue ( 'withNameValueParent' , SAMPLE_ALIQUOT_IMPORT_TYPE_NAME ) ;
575+ await verifyImportingWithNameValue ( selectRandomN ( parentSampleName , 1 ) [ 0 ] , SAMPLE_ALIQUOT_IMPORT_TYPE_NAME ) ;
570576 } ) ;
571577
572578 /**
@@ -583,8 +589,8 @@ describe('Aliquot crud', () => {
583589 * </ul>
584590 * </p>
585591 */
586- it ( 'testImportingWithNameValue - without naming patten' , async ( ) => {
587- await verifyImportingWithNameValue ( 'withNameValueParentNoPattern' , SAMPLE_ALIQUOT_IMPORT_NO_NAME_PATTERN_NAME ) ;
592+ it ( '(Fuzz Test) testImportingWithNameValue - without naming patten' , async ( ) => {
593+ await verifyImportingWithNameValue ( selectRandomN ( parentSampleName , 1 ) [ 0 ] , SAMPLE_ALIQUOT_IMPORT_NO_NAME_PATTERN_NAME ) ;
588594 } ) ;
589595
590596 async function verifyMultipleRootsAndAliquots ( parentSampleName1 : string , parentSampleName2 : string , sampleType : string ) {
0 commit comments