Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Modified.UTC() instead of deprecated ModTime() #81

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions fs/fs_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ func TestOpen(t *testing.T) {
"/file.txt": {
data: mustReadFile("../testdata/file/file.txt"),
isDir: false,
modTime: fileTxtHeader.ModTime(),
modTime: fileTxtHeader.Modified.UTC(),
mode: fileTxtHeader.Mode(),
name: fileTxtHeader.Name,
size: int64(fileTxtHeader.UncompressedSize64),
Expand All @@ -72,7 +72,7 @@ func TestOpen(t *testing.T) {
"/pixel.gif": {
data: mustReadFile("../testdata/image/pixel.gif"),
isDir: false,
modTime: pixelGifHeader.ModTime(),
modTime: pixelGifHeader.Modified.UTC(),
mode: pixelGifHeader.Mode(),
name: pixelGifHeader.Name,
size: int64(pixelGifHeader.UncompressedSize64),
Expand All @@ -86,15 +86,15 @@ func TestOpen(t *testing.T) {
"/index.html": {
data: mustReadFile("../testdata/index/index.html"),
isDir: false,
modTime: indexHTMLHeader.ModTime(),
modTime: indexHTMLHeader.Modified.UTC(),
mode: indexHTMLHeader.Mode(),
name: indexHTMLHeader.Name,
size: int64(indexHTMLHeader.UncompressedSize64),
},
"/sub_dir/index.html": {
data: mustReadFile("../testdata/index/sub_dir/index.html"),
isDir: false,
modTime: subdirIndexHTMLHeader.ModTime(),
modTime: subdirIndexHTMLHeader.Modified.UTC(),
mode: subdirIndexHTMLHeader.Mode(),
name: subdirIndexHTMLHeader.Name,
size: int64(subdirIndexHTMLHeader.UncompressedSize64),
Expand Down Expand Up @@ -127,15 +127,15 @@ func TestOpen(t *testing.T) {
"/a": {
data: mustReadFile("../testdata/deep/a"),
isDir: false,
modTime: deepAHTMLHeader.ModTime(),
modTime: deepAHTMLHeader.Modified.UTC(),
mode: deepAHTMLHeader.Mode(),
name: deepAHTMLHeader.Name,
size: int64(deepAHTMLHeader.UncompressedSize64),
},
"/aa/bb/c": {
data: mustReadFile("../testdata/deep/aa/bb/c"),
isDir: false,
modTime: deepCHTMLHeader.ModTime(),
modTime: deepCHTMLHeader.Modified.UTC(),
mode: deepCHTMLHeader.Mode(),
name: deepCHTMLHeader.Name,
size: int64(deepCHTMLHeader.UncompressedSize64),
Expand Down Expand Up @@ -164,7 +164,7 @@ func TestOpen(t *testing.T) {
"/../file/../file/../file/.//file.txt": {
data: mustReadFile("../testdata/file/file.txt"),
isDir: false,
modTime: fileTxtHeader.ModTime(),
modTime: fileTxtHeader.Modified.UTC(),
mode: fileTxtHeader.Mode(),
name: fileTxtHeader.Name,
size: int64(fileTxtHeader.UncompressedSize64),
Expand Down