blob: 2daecf920d3623f7e0675a42e75ee7b71b1eb52e (
plain)
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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
{
lib,
buildPythonPackage,
fetchFromGitHub,
# build inputs
setuptools,
setuptools-scm,
typing-extensions,
}:
buildPythonPackage rec {
pname = "widlparser";
version = "1.4.0";
pyproject = true;
src = fetchFromGitHub {
owner = "plinss";
repo = "widlparser";
rev = "v${version}";
hash = "sha256-vYDldZH49GfNRjKh3x0DX05jYFOLQtA//7bw+B16O1M=";
};
build-system = [
setuptools
setuptools-scm
];
dependencies = [ typing-extensions ];
pythonImportsCheck = [ "widlparser" ];
# https://github.com/plinss/widlparser/blob/v1.4.0/.github/workflows/test.yml
checkPhase = ''
runHook preCheck
python test.py > test-actual.txt
diff -u test-expected.txt test-actual.txt
runHook postCheck
'';
meta = {
description = "Stand-alone WebIDL Parser in Python";
homepage = "https://github.com/plinss/widlparser";
license = lib.licenses.mit;
maintainers = [ ];
};
}
|