Merge pull request #91675 from MetaDark/cxxtest

cxxtest: package includes and run tests
This commit is contained in:
Mario Rodas 2020-11-02 05:02:35 -05:00 committed by GitHub
commit 8eea6fcf0d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 17 additions and 9 deletions

View File

@ -1,10 +1,8 @@
{ stdenv, fetchFromGitHub, python2Packages}: { stdenv, buildPythonApplication, fetchFromGitHub }:
let buildPythonApplication rec {
pname = "cxxtest"; pname = "cxxtest";
version = "4.4"; version = "4.4";
in python2Packages.buildPythonApplication {
name = "${pname}-${version}";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "CxxTest"; owner = "CxxTest";
@ -13,10 +11,21 @@ in python2Packages.buildPythonApplication {
sha256 = "19w92kipfhp5wvs47l0qpibn3x49sbmvkk91yxw6nwk6fafcdl17"; sha256 = "19w92kipfhp5wvs47l0qpibn3x49sbmvkk91yxw6nwk6fafcdl17";
}; };
setSourceRoot = '' sourceRoot = "source/python";
sourceRoot=$(echo */python)
postCheck = ''
python scripts/cxxtestgen --error-printer -o build/GoodSuite.cpp ../test/GoodSuite.h
$CXX -I.. -o build/GoodSuite build/GoodSuite.cpp
build/GoodSuite
''; '';
postInstall = ''
mkdir -p "$out/include"
cp -r ../cxxtest "$out/include"
'';
dontWrapPythonPrograms = true;
meta = with stdenv.lib; { meta = with stdenv.lib; {
homepage = "http://cxxtest.com"; homepage = "http://cxxtest.com";
description = "Unit testing framework for C++"; description = "Unit testing framework for C++";
@ -25,4 +34,3 @@ in python2Packages.buildPythonApplication {
maintainers = [ maintainers.juliendehos ]; maintainers = [ maintainers.juliendehos ];
}; };
} }

View File

@ -12351,7 +12351,7 @@ in
cxx-prettyprint = callPackage ../development/libraries/cxx-prettyprint { }; cxx-prettyprint = callPackage ../development/libraries/cxx-prettyprint { };
cxxtest = callPackage ../development/libraries/cxxtest { }; cxxtest = python2Packages.callPackage ../development/libraries/cxxtest { };
cypress = callPackage ../development/web/cypress { }; cypress = callPackage ../development/web/cypress { };