aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2019-04-22 12:31:29 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2019-04-22 12:31:29 -0300
commit20b161e2859837e4f7fb1c19440ad7efe1588f1f (patch)
treeb86703d747a674930f6573d765d6c9600eb1d8b8
parented2872cd3bf6d352f36bbd34529738a60b0b51eb (diff)
downloadlua-20b161e2859837e4f7fb1c19440ad7efe1588f1f.tar.gz
lua-20b161e2859837e4f7fb1c19440ad7efe1588f1f.tar.bz2
lua-20b161e2859837e4f7fb1c19440ad7efe1588f1f.zip
Small correction in test about 'isdst'
The field 'isdst' can be false, so we cannot test its absence with 'if not D.isdst'; we must compare with nil for a correct test.
-rw-r--r--testes/files.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/testes/files.lua b/testes/files.lua
index 0a05cf60..38d3a669 100644
--- a/testes/files.lua
+++ b/testes/files.lua
@@ -832,7 +832,7 @@ load(os.date([[!assert(D.year==%Y and D.month==%m and D.day==%d and
832do 832do
833 local D = os.date("*t") 833 local D = os.date("*t")
834 local t = os.time(D) 834 local t = os.time(D)
835 if not D.isdst then 835 if D.isdst == nil then
836 print("no daylight saving information") 836 print("no daylight saving information")
837 else 837 else
838 assert(type(D.isdst) == 'boolean') 838 assert(type(D.isdst) == 'boolean')