mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-11-29 14:31:30 +08:00
a23bcbb7ec
The io/ioutil package has been deprecated as of Go 1.16, see https://golang.org/doc/go1.16#ioutil. This commit replaces the existing io/ioutil functions with their new definitions in io and os packages. Signed-off-by: Eng Zer Jun <engzerjun@gmail.com>
20 lines
244 B
Go
20 lines
244 B
Go
package images
|
|
|
|
import (
|
|
"os"
|
|
"testing"
|
|
)
|
|
|
|
func TestXYZ(t *testing.T) {
|
|
fname := "sample1.jpg"
|
|
|
|
dat, _ := os.ReadFile(fname)
|
|
|
|
fixed_data := FixJpgOrientation(dat)
|
|
|
|
os.WriteFile("fixed1.jpg", fixed_data, 0644)
|
|
|
|
os.Remove("fixed1.jpg")
|
|
|
|
}
|