summaryrefslogtreecommitdiff
path: root/var/spack/repos/builtin.mock/packages/url-list-test/package.py
blob: 98d7af842527e10bf35bf64b1994e24e3a097983 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# Copyright 2013-2018 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)

from spack import *

import os
import spack.paths


class UrlListTest(Package):
    """Mock package with url_list."""
    homepage = "http://www.url-list-example.com"

    web_data_path = os.path.join(spack.paths.test_path, 'data', 'web')
    url = 'file://' + web_data_path + '/foo-0.0.0.tar.gz'
    list_url = 'file://' + web_data_path + '/index.html'
    list_depth = 3

    version('0.0.0',   'abc000')
    version('1.0.0',   'abc100')
    version('3.0',     'abc30')
    version('4.5',     'abc45')
    version('2.0.0b2', 'abc200b2')
    version('3.0a1',   'abc30a1')
    version('4.5-rc5', 'abc45rc5')

    def install(self, spec, prefix):
        pass