Bug 204155 - bin/ls/ls_tests:l_flag test fails
Summary: bin/ls/ls_tests:l_flag test fails
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: tests (show other bugs)
Version: CURRENT
Hardware: arm64 Any
: --- Affects Only Me
Assignee: Ed Maste
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-10-30 17:23 UTC by Ed Maste
Modified: 2015-10-30 20:15 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ed Maste freebsd_committer freebsd_triage 2015-10-30 17:23:51 UTC
Somehow it's passing -l to the date command

Standard output

Executing command [ touch a.file ]
Executing command [ ls -l a.file ]

Standard error

date: illegal option -- 1
usage: date [-jnRu] [-d dst] [-r seconds] [-t west] [-v[+|-]val[ymwdHMS]] ... 
            [-f fmt date | [[[[[cc]yy]mm]dd]HH]MM[.ss]] [+format]
Fail: regexp -rw-r--r--[[:space:]]+1[[:space:]]+tests[[:space:]]+nobody[[:space:]]+0[[:space:]]+[[:space:]]+a\.file not in stdout
-rw-r--r--  1 tests  nobody  0 Oct 29 07:16 a.file
Comment 1 Allan Jude freebsd_committer freebsd_triage 2015-10-30 19:05:36 UTC
The error message appears to be complaining about -1 (one) not -l (ell)
Comment 2 Ed Maste freebsd_committer freebsd_triage 2015-10-30 19:20:42 UTC
Oh yes, console font fail.

root@cavium:~ # touch a.file
root@cavium:~ # stat -f "%B" -t "%s" a.file
-1
root@cavium:~ # stat a.file
66 52 -rw-r--r-- 1 root wheel 0 0 "Oct 29 10:06:52 2015" "Oct 29 10:06:52 2015" "Oct 29 10:06:52 2015" "Dec 31 23:59:59 1969" 8192 0 0 a.file
root@cavium:~ # date
Thu Oct 29 10:07:47 UTC 2015
Comment 3 Ed Maste freebsd_committer freebsd_triage 2015-10-30 19:25:49 UTC
https://reviews.freebsd.org/D4040
Comment 4 Ed Maste freebsd_committer freebsd_triage 2015-10-30 20:15:14 UTC
Committed as r290205
Comment 5 commit-hook freebsd_committer freebsd_triage 2015-10-30 20:15:35 UTC
A commit references this bug:

Author: emaste
Date: Fri Oct 30 20:14:32 UTC 2015
New revision: 290205
URL: https://svnweb.freebsd.org/changeset/base/290205

Log:
  Update ls -l tests to use mtime, not birthtime

  PR:		204155
  Reviewed by:	ngie, rodrigc
  Sponsored by:	The FreeBSD Foundation
  Differential Revision:	https://reviews.freebsd.org/D4040

Changes:
  head/bin/ls/tests/ls_tests.sh