File: fix_unpredictable-order-at-empty-attr-test.patch

package info (click to toggle)
libxml-hash-lx-perl 0.0603-1
  • links: PTS, VCS
  • area: main
  • in suites: buster, stretch
  • size: 412 kB
  • ctags: 158
  • sloc: perl: 2,603; makefile: 5
file content (29 lines) | stat: -rw-r--r-- 1,023 bytes parent folder | download | duplicates (3)
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
Description: Fix unpredictable order at 'empty attr' test
 Hash key randomization was introduced and it seems at least the test
 t/01-conv.t is hit by that. This patch intend to fix this issue in 'empty
 attr' test.
Author: Petr Písař <ppisar@redhat.com>
Last-Update: 2014-06-9
Reviewed-by: Lucas Kanashiro <kanashiro.duarte@gmail.com>
Forwarded: https://rt.cpan.org/Public/Bug/Display.html?id=81645

---
 t/01-conv.t | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/t/01-conv.t b/t/01-conv.t
index f7b06c5..30f24dc 100644
--- a/t/01-conv.t
+++ b/t/01-conv.t
@@ -297,7 +297,7 @@ our $xml = qq{<?xml version="1.0" encoding="utf-8"?>\n};
 }
 {
 	is
-		$data = hash2xml( { node => { -attr => undef, '#cdata' => undef, '/' => undef, x=>undef } }, cdata => '#cdata', comm => '/' ),
+		$data = hash2xml( { node => [ { -attr => undef }, { '#cdata' => undef }, { '/' => undef }, { x=>undef } ] }, cdata => '#cdata', comm => '/' ),
 		qq{$xml<node attr=""><!----><x/></node>\n},
 		'empty attr',
 	;
-- 
1.9.3