Changing the fasterq-dump container now gives me a...
# fetchngs
s
Changing the fasterq-dump container now gives me a new error:
Copy code
Command error:
    This sra toolkit installation has not been configured.
    Before continuing, please run: vdb-config --interactive
    For more information, see <https://www.ncbi.nlm.nih.gov/sra/docs/sra-cloud/>
With a
nf-test
module test
Copy code
nextflow_process {
    name "Test Process SRATOOLS_FASTERQDUMP"
    script "modules/local/sratools/fasterqdump/main.nf"
    process "SRATOOLS_FASTERQDUMP"
    tag "modules"
    tag "modules_nfcore"
    tag "sratools/fasterqdump"

    test("Test fasterqdump ERR1109373") {

        when {
            process {
                """
                input[0] = Channel.of([ [irida_id: "SAMPLE1"], file("$baseDir/tests/data/ERR1109373.sra", checkIfExists: true) ])
                input[1] = []
                input[2] = []
                """
            }

            params {
                outdir = "fasterqdump_test1_out"
            }
        }

        then {
            assert process.success
            assert snapshot(process.out).match()
        }
    }
}
m
did you try to provide a config file?
it seems to me that's your issue there
s
I don't believe I tried using a config file for tests. I'll try that thanks!
m
Please let me know if it worked, or if you have any issues left
s
I was able to implement it last night! It worked thanks so much!
I made a
ncbi_user_settings.mkfg
file like you suggested and added it into the test via the input[1].
Copy code
nextflow_process {
    name "Test Process SRATOOLS_FASTERQDUMP"
    script "modules/local/sratools/fasterqdump/main.nf"
    process "SRATOOLS_FASTERQDUMP"
    tag "modules"
    tag "modules_nfcore"
    tag "sratools/fasterqdump"

    test("Test fasterqdump ERR1109373") {

        when {
            process {
                """
                input[0] = Channel.of([ [irida_id: "SAMPLE1"], file("$baseDir/tests/data/ERR1109373.sra", checkIfExists: true) ])
                input[1] = file('$baseDir/tests/data/ncbi_user_settings.mkfg', checkIfExists: true)
                input[2] = []
                """
            }

            params {
                outdir = "fasterqdump_test1_out"
            }
        }

        then {
            assert process.success
            assert snapshot(process.out).match()
        }
    }
}
🎉 1
m
Wonderful