From cbb64983aca425e0bddd9896fb13609c9b47217a Mon Sep 17 00:00:00 2001
From: Thomas Schwinge <thomas@codesourcery.com>
Date: Sun, 8 Apr 2012 19:35:53 +0200
Subject: [PATCH] tests: tar --concatenate with multiple files is broken.

* tests/concatenate.at: New file.
* tests/Makefile.am (TESTSUITE_AT): Add it.
* tests/testsuite.at: Include it.
---
 tests/Makefile.am    |    1 +
 tests/concatenate.at |   41 +++++++++++++++++++++++++++++++++++++++++
 tests/testsuite.at   |    2 ++
 3 files changed, 44 insertions(+), 0 deletions(-)
 create mode 100644 tests/concatenate.at

diff --git a/tests/Makefile.am b/tests/Makefile.am
index 4601e0e..8aa3e82 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -56,6 +56,7 @@ TESTSUITE_AT = \
  backup01.at\
  chtype.at\
  comprec.at\
+ concatenate.at\
  delete01.at\
  delete02.at\
  delete03.at\
diff --git a/tests/concatenate.at b/tests/concatenate.at
new file mode 100644
index 0000000..bf8fb2d
--- /dev/null
+++ b/tests/concatenate.at
@@ -0,0 +1,41 @@
+# Process this file with autom4te to create testsuite. -*- Autotest -*-
+
+# Test suite for GNU tar.
+# Copyright (C) 2012 Free Software Foundation, Inc.
+
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3, or (at your option)
+# any later version.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
+# 02110-1301, USA.
+
+
+AT_SETUP([tar --concatenate with multiple files])
+AT_KEYWORDS([concatenate])
+
+# <http://lists.gnu.org/archive/html/bug-tar/2008-08/msg00002.html>
+AT_XFAIL_IF([true])
+
+AT_TAR_CHECK(
+[touch one two three
+tar cf one.tar one
+tar cf two.tar two
+tar cf three.tar three
+tar --concatenate -f one.tar two.tar three.tar
+tar tf one.tar],
+[0],
+[one
+two
+three
+])
+
+AT_CLEANUP
diff --git a/tests/testsuite.at b/tests/testsuite.at
index 97f5e41..ba9f369 100644
--- a/tests/testsuite.at
+++ b/tests/testsuite.at
@@ -131,6 +131,8 @@ m4_include([append01.at])
 m4_include([append02.at])
 m4_include([append03.at])
 
+m4_include([concatenate.at])
+
 m4_include([xform-h.at])
 m4_include([xform01.at])
 
-- 
1.7.9

