From owner-svn-src-head@freebsd.org Sat Apr 22 23:27:41 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id D9D46D4B74B; Sat, 22 Apr 2017 23:27:41 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 91F6EE6E; Sat, 22 Apr 2017 23:27:41 +0000 (UTC) (envelope-from ngie@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id v3MNReBK046134; Sat, 22 Apr 2017 23:27:40 GMT (envelope-from ngie@FreeBSD.org) Received: (from ngie@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id v3MNRemm046133; Sat, 22 Apr 2017 23:27:40 GMT (envelope-from ngie@FreeBSD.org) Message-Id: <201704222327.v3MNRemm046133@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ngie set sender to ngie@FreeBSD.org using -f From: Ngie Cooper Date: Sat, 22 Apr 2017 23:27:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r317308 - head/tools/regression/geom_gpt X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 22 Apr 2017 23:27:42 -0000 Author: ngie Date: Sat Apr 22 23:27:40 2017 New Revision: 317308 URL: https://svnweb.freebsd.org/changeset/base/317308 Log: gctl_test.t: more tweaks to try and update the code and get it functional (again?) - Make the logfile for $out be built off the basename for $cmd, instead of $cmd. (r317292 broke this assumption). - Rename $mntpt to $mntpt_prefix for clarity, as this variable is a prefix for mountpoints. - Reindent the umount directive block while here to match the rest of the code. MFC after: 5 weeks Sponsored by: Dell EMC Isilon Modified: head/tools/regression/geom_gpt/gctl_test.t Modified: head/tools/regression/geom_gpt/gctl_test.t ============================================================================== --- head/tools/regression/geom_gpt/gctl_test.t Sat Apr 22 23:06:53 2017 (r317307) +++ head/tools/regression/geom_gpt/gctl_test.t Sat Apr 22 23:27:40 2017 (r317308) @@ -29,8 +29,10 @@ use strict; use warnings; +use File::Basename; + my $disk = "/tmp/disk-$$"; -my $mntpt = "/tmp/mount-$$"; +my $mntpt_prefix = "/tmp/mount-$$"; my %steps = ( "000" => "gctl", @@ -137,7 +139,7 @@ if ($st != 0) { } chomp(my $cmd = `make '-V\${.OBJDIR}/\${PROG}'`); -my $out = "/tmp/$cmd.out"; +my $out = basename($cmd) . ".out"; # Make sure we have permission to use gctl... if (`$cmd` =~ "^FAIL Permission denied") { @@ -192,14 +194,14 @@ foreach my $key (sort keys %steps) { } unlink $out; } elsif ($action =~ "^mount") { - system("mkdir $mntpt-$args"); + system("mkdir $mntpt_prefix-$args"); system("newfs $args"); - system("mount -t ufs /dev/$args $mntpt-$args"); + system("mount -t ufs /dev/$args $mntpt_prefix-$args"); print "ok $nr \# mount($key)\n"; } elsif ($action =~ "^umount") { - system("umount $mntpt-$args"); - system("rmdir $mntpt-$args"); - print "ok $nr \# umount($key)\n"; + system("umount $mntpt_prefix-$args"); + system("rmdir $mntpt_prefix-$args"); + print "ok $nr \# umount($key)\n"; } $nr += 1; }