summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorLars-Dominik Braun <lars@6xq.net>2022-04-30 15:39:51 +0200
committerLars-Dominik Braun <lars@6xq.net>2022-06-06 13:26:45 +0200
commit001e0bac99c977d2ff04910295b154f91aa3d369 (patch)
tree2a9001111e47d663e69a2e9a75b9e95fabf52961 /tests
parent0972feaff1f766c1759d0b89876132ae473725ce (diff)
downloadguix-001e0bac99c977d2ff04910295b154f91aa3d369.tar.gz
guix-001e0bac99c977d2ff04910295b154f91aa3d369.tar.xz
import: cabal: Allow properties without space between key and value.
* guix/import/cabal.scm (lex-word): Add colon to delimiters. * tests/hackage.scm (test-cabal-property-no-space): New variable. ("hackage->guix-package test properties without space"): New test.
Diffstat (limited to 'tests')
-rw-r--r--tests/hackage.scm19
1 files changed, 19 insertions, 0 deletions
diff --git a/tests/hackage.scm b/tests/hackage.scm
index 15309a3381..4ce48b6baf 100644
--- a/tests/hackage.scm
+++ b/tests/hackage.scm
@@ -315,6 +315,25 @@ executable cabal
(test-assert "hackage->guix-package test flag executable"
(eval-test-with-cabal test-cabal-flag-executable match-ghc-foo))
+;; There is no mandatory space between property name and value.
+(define test-cabal-property-no-space
+ "name:foo
+version:1.0.0
+homepage:http://test.org
+synopsis:synopsis
+description:description
+license:BSD3
+common bench-defaults
+ ghc-options:-Wall
+executable cabal
+ build-depends:
+ HTTP >= 4000.2.5 && < 4000.3,
+ mtl >= 2.0 && < 3
+")
+
+(test-assert "hackage->guix-package test properties without space"
+ (eval-test-with-cabal test-cabal-property-no-space match-ghc-foo))
+
;; Check if-elif-else statements
(define test-cabal-if
"name: foo