예제 #1
0
def test_cmake_bad_generator(config, mock_packages):
    s = Spec('cmake-client')
    s.concretize()
    pkg = spack.repo.get(s)
    pkg.generator = 'Yellow Sticky Notes'
    with pytest.raises(spack.package.InstallError):
        get_std_cmake_args(pkg)
예제 #2
0
    def test_cmake_std_args(self):
        # Call the function on a CMakePackage instance
        s = Spec('cmake-client').concretized()
        assert s.package.std_cmake_args == get_std_cmake_args(s.package)

        # Call it on another kind of package
        s = Spec('mpich').concretized()
        assert get_std_cmake_args(s.package)
예제 #3
0
def test_cmake_std_args(config, mock_packages):
    # Call the function on a CMakePackage instance
    s = Spec('cmake-client')
    s.concretize()
    pkg = spack.repo.get(s)
    assert pkg.std_cmake_args == get_std_cmake_args(pkg)

    # Call it on another kind of package
    s = Spec('mpich')
    s.concretize()
    pkg = spack.repo.get(s)
    assert get_std_cmake_args(pkg)
예제 #4
0
def test_cmake_std_args(config, builtin_mock):
    # Call the function on a CMakePackage instance
    s = Spec('cmake-client')
    s.concretize()
    pkg = spack.repo.get(s)
    assert pkg.std_cmake_args == get_std_cmake_args(pkg)

    # Call it on another kind of package
    s = Spec('mpich')
    s.concretize()
    pkg = spack.repo.get(s)
    assert get_std_cmake_args(pkg)
예제 #5
0
def test_cmake_secondary_generator(config, mock_packages):
    s = Spec('cmake-client')
    s.concretize()
    pkg = spack.repo.get(s)
    pkg.generator = 'CodeBlocks - Unix Makefiles'
    assert get_std_cmake_args(pkg)
예제 #6
0
 def test_cmake_secondary_generator(config, mock_packages):
     s = Spec('cmake-client').concretized()
     s.package.generator = 'CodeBlocks - Unix Makefiles'
     assert get_std_cmake_args(s.package)
예제 #7
0
 def test_cmake_bad_generator(self):
     s = Spec('cmake-client').concretized()
     s.package.generator = 'Yellow Sticky Notes'
     with pytest.raises(spack.package_base.InstallError):
         get_std_cmake_args(s.package)