public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
From: Li Wang <liwang@redhat.com>
To: ltp@lists.linux.it
Subject: [LTP] [PATCH] ltp: test id usually same as test filename without suffix
Date: Mon, 13 Mar 2017 19:35:26 +0800	[thread overview]
Message-ID: <20170313113526.31763-1-liwang@redhat.com> (raw)

Perform this script under ltp root dir.

 $ cat fix_tid.sh
 #!/bin/bash

 for file in `find -name *.c`; do
 	value=$(echo $(basename ${file%%.c}));
 	sed -i "/\.tid/s/\".*\"/\"$value\"/g" $file
 done

Signed-off-by: Li Wang <liwang@redhat.com>
---
 lib/newlib_tests/test03.c                         | 2 +-
 testcases/kernel/syscalls/add_key/add_key02.c     | 2 +-
 testcases/kernel/syscalls/ioctl/ioctl06.c         | 2 +-
 testcases/kernel/syscalls/mq_unlink/mq_unlink01.c | 2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/lib/newlib_tests/test03.c b/lib/newlib_tests/test03.c
index c1983ad..d5772a8 100644
--- a/lib/newlib_tests/test03.c
+++ b/lib/newlib_tests/test03.c
@@ -28,6 +28,6 @@ static void do_test(void)
 }
 
 static struct tst_test test = {
-	.tid = "test02",
+	.tid = "test03",
 	.test_all = do_test,
 };
diff --git a/testcases/kernel/syscalls/add_key/add_key02.c b/testcases/kernel/syscalls/add_key/add_key02.c
index e954575..fc99191 100644
--- a/testcases/kernel/syscalls/add_key/add_key02.c
+++ b/testcases/kernel/syscalls/add_key/add_key02.c
@@ -69,7 +69,7 @@ static void verify_add_key(unsigned int i)
 }
 
 static struct tst_test test = {
-	.tid = "add_key01",
+	.tid = "add_key02",
 	.tcnt = ARRAY_SIZE(tcases),
 	.test = verify_add_key,
 };
diff --git a/testcases/kernel/syscalls/ioctl/ioctl06.c b/testcases/kernel/syscalls/ioctl/ioctl06.c
index 9046a3f..d05aa45 100644
--- a/testcases/kernel/syscalls/ioctl/ioctl06.c
+++ b/testcases/kernel/syscalls/ioctl/ioctl06.c
@@ -63,7 +63,7 @@ static void cleanup(void)
 }
 
 static struct tst_test test = {
-	.tid = "ioctl07",
+	.tid = "ioctl06",
 	.needs_device = 1,
 	.setup = setup,
 	.cleanup = cleanup,
diff --git a/testcases/kernel/syscalls/mq_unlink/mq_unlink01.c b/testcases/kernel/syscalls/mq_unlink/mq_unlink01.c
index 03ce3f8..40f6db2 100644
--- a/testcases/kernel/syscalls/mq_unlink/mq_unlink01.c
+++ b/testcases/kernel/syscalls/mq_unlink/mq_unlink01.c
@@ -124,7 +124,7 @@ EXIT:
 }
 
 static struct tst_test test = {
-	.tid = "mq_ulink01",
+	.tid = "mq_unlink01",
 	.tcnt = ARRAY_SIZE(tcase),
 	.test = do_test,
 	.needs_root = 1,
-- 
2.9.3


             reply	other threads:[~2017-03-13 11:35 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-13 11:35 Li Wang [this message]
2017-03-13 13:29 ` [LTP] [PATCH] ltp: test id usually same as test filename without suffix Cyril Hrubis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170313113526.31763-1-liwang@redhat.com \
    --to=liwang@redhat.com \
    --cc=ltp@lists.linux.it \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox