/*
 * -------------------------------------------------
 *  Nextflow config file for running tests
 * -------------------------------------------------
 * Defines bundled input files and everything required
 * to run a fast and simple test. Use as follows:
 *   nextflow run nf-core/airrflow -profile <docker/singularity> -c conf/test_no-umi.config
 */

params {
    config_profile_name = 'Test profile without UMIs'
    config_profile_description = 'Test dataset without UMIs to check pipeline function.'

    // Limit resources so that this can run on GitHub Actions
    max_cpus = 2
    max_memory = 6.GB
    max_time = 6.h

    mode = 'fastq'

    cprimer_position = 'R1'
    library_generation_method = 'specific_pcr'
    cprimer_start = 4
    vprimer_start = 4
    primer_revpr = true
    umi_length = 0
    isotype_column = 'c_primer'

    // Input data
    input = 'https://raw.githubusercontent.com/nf-core/test-datasets/airrflow/testdata-no-umi/Metadata_test-no-umi_airr.tsv'
    cprimers = 'https://raw.githubusercontent.com/nf-core/test-datasets/airrflow/testdata-no-umi/Greiff2014_CPrimers.fasta'
    vprimers = 'https://raw.githubusercontent.com/nf-core/test-datasets/airrflow/testdata-no-umi/Greiff2014_VPrimers.fasta'
    imgtdb_base = 'https://raw.githubusercontent.com/nf-core/test-datasets/airrflow/database-cache/imgtdb_base.zip'
    igblast_base = 'https://raw.githubusercontent.com/nf-core/test-datasets/airrflow/database-cache/igblast_base.zip'


}
process {
    // When not using UMIs, set the coord parameter based on source (e.g., sra or illumina)
    withName: PRESTO_ASSEMBLEPAIRS_SANS_UMI {
            ext.args = '--rc tail --coord sra --maxerror 0.3'
    }
    withName:"DEFINE_CLONES*"{
        ext.args = ['outname':'', 'model':'hierarchical',
                    'method':'nt', 'linkage':'single',
                    'outputby':'sample_id', 'min_n':10]
    }
}

