Debian Codegraph @

tools/humanize/humanize_test.go

raw symbols SCIP
1 package humanize_testscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/
2
3 import (
4 "mathscip-go gomod github.com/golang/go/src go1.25.0 math/"
5 "testingscip-go gomod github.com/golang/go/src go1.25.0 testing/"
6 "timescip-go gomod github.com/golang/go/src go1.25.0 time/"
7
8 "github.com/git-lfs/git-lfs/v3/tools/humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/"
9 "github.com/stretchr/testify/assertscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/"
10 )
11
12 type ParseBytesTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseBytesTestCase# struct {
13 Givenscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseBytesTestCase#Given. string
14 Expectedscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseBytesTestCase#Expected. uint64
15 Errscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseBytesTestCase#Err. error
16 }
17
18 func (c *ParseBytesTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseBytesTestCase#) Assertscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseBytesTestCase#Assert().(t *testingscip-go gomod github.com/golang/go/src go1.25.0 testing/.Tscip-go gomod github.com/golang/go/src go1.25.0 testing/T#) {
19 got, err := humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.ParseBytesscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/ParseBytes().(c.Givenscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseBytesTestCase#Given.)
20 if c.Errscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseBytesTestCase#Err. == nil {
21 assertscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/.NoErrorscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/NoError().(t, err, "unexpected error: %s", err)
22 assertscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/.EqualValuesscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/EqualValues().(t, c.Expectedscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseBytesTestCase#Expected., got)
23 } else {
24 assertscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/.Equalscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/Equal().(t, c.Errscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseBytesTestCase#Err., err)
25 }
26 }
27
28 type FormatBytesTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesTestCase# struct {
29 Givenscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesTestCase#Given. uint64
30 Expectedscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesTestCase#Expected. string
31 }
32
33 func (c *FormatBytesTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesTestCase#) Assertscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesTestCase#Assert().(t *testingscip-go gomod github.com/golang/go/src go1.25.0 testing/.Tscip-go gomod github.com/golang/go/src go1.25.0 testing/T#) {
34 assertscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/.Equalscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/Equal().(t, c.Expectedscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesTestCase#Expected., humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.FormatBytesscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/FormatBytes().(c.Givenscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesTestCase#Given.))
35 }
36
37 type ParseByteUnitTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseByteUnitTestCase# struct {
38 Givenscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseByteUnitTestCase#Given. string
39 Expectedscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseByteUnitTestCase#Expected. uint64
40 Errscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseByteUnitTestCase#Err. string
41 }
42
43 func (c *ParseByteUnitTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseByteUnitTestCase#) Assertscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseByteUnitTestCase#Assert().(t *testingscip-go gomod github.com/golang/go/src go1.25.0 testing/.Tscip-go gomod github.com/golang/go/src go1.25.0 testing/T#) {
44 got, err := humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.ParseByteUnitscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/ParseByteUnit().(c.Givenscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseByteUnitTestCase#Given.)
45 if len(c.Errscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseByteUnitTestCase#Err.) == 0 {
46 assertscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/.NoErrorscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/NoError().(t, err, "unexpected error: %s", err)
47 assertscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/.EqualValuesscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/EqualValues().(t, c.Expectedscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseByteUnitTestCase#Expected., got)
48 } else {
49 assertscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/.EqualErrorscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/EqualError().(t, err, c.Errscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseByteUnitTestCase#Err.)
50 }
51 }
52
53 type FormatBytesUnitTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesUnitTestCase# struct {
54 Givenscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesUnitTestCase#Given. uint64
55 Unitscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesUnitTestCase#Unit. uint64
56 Expectedscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesUnitTestCase#Expected. string
57 }
58
59 func (c *FormatBytesUnitTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesUnitTestCase#) Assertscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesUnitTestCase#Assert().(t *testingscip-go gomod github.com/golang/go/src go1.25.0 testing/.Tscip-go gomod github.com/golang/go/src go1.25.0 testing/T#) {
60 assertscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/.Equalscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/Equal().(t, c.Expectedscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesUnitTestCase#Expected., humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.FormatBytesUnitscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/FormatBytesUnit().(c.Givenscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesUnitTestCase#Given., c.Unitscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesUnitTestCase#Unit.))
61 }
62
63 type FormatByteRateTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatByteRateTestCase# struct {
64 Givenscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatByteRateTestCase#Given. uint64
65 Overscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatByteRateTestCase#Over. timescip-go gomod github.com/golang/go/src go1.25.0 time/.Durationscip-go gomod github.com/golang/go/src go1.25.0 time/Duration#
66 Expectedscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatByteRateTestCase#Expected. string
67 }
68
69 func (c *FormatByteRateTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatByteRateTestCase#) Assertscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatByteRateTestCase#Assert().(t *testingscip-go gomod github.com/golang/go/src go1.25.0 testing/.Tscip-go gomod github.com/golang/go/src go1.25.0 testing/T#) {
70 assertscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/.Equalscip-go gomod github.com/stretchr/testify v1.11.1 `github.com/stretchr/testify/assert`/Equal().(t, c.Expectedscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatByteRateTestCase#Expected., humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.FormatByteRatescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/FormatByteRate().(c.Givenscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatByteRateTestCase#Given., c.Overscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatByteRateTestCase#Over.))
71 }
72
73 func TestParseBytesscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/TestParseBytes().(t *testingscip-go gomod github.com/golang/go/src go1.25.0 testing/.Tscip-go gomod github.com/golang/go/src go1.25.0 testing/T#) {
74 for desc, c := range map[string]*ParseBytesTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseBytesTestCase#{
75 "parse byte (zero, empty)": {"", uint64(0), nil},
76 "parse byte (empty)": {"10", uint64(10 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 0)), nil},
77 "parse byte": {"10B", uint64(10 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 0)), nil},
78 "parse kibibyte": {"20KIB", uint64(20 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 10)), nil},
79 "parse mebibyte": {"30MIB", uint64(30 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 20)), nil},
80 "parse gibibyte": {"40GIB", uint64(40 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 30)), nil},
81 "parse tebibyte": {"50TIB", uint64(50 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 40)), nil},
82 "parse pebibyte": {"60PIB", uint64(60 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 50)), nil},
83
84 "parse byte (lowercase)": {"10b", uint64(10 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 0)), nil},
85 "parse kibibyte (lowercase)": {"20kib", uint64(20 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 10)), nil},
86 "parse mebibyte (lowercase)": {"30mib", uint64(30 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 20)), nil},
87 "parse gibibyte (lowercase)": {"40gib", uint64(40 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 30)), nil},
88 "parse tebibyte (lowercase)": {"50tib", uint64(50 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 40)), nil},
89 "parse pebibyte (lowercase)": {"60pib", uint64(60 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 50)), nil},
90
91 "parse byte (with space)": {"10 B", uint64(10 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 0)), nil},
92 "parse kibibyte (with space)": {"20 KIB", uint64(20 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 10)), nil},
93 "parse mebibyte (with space)": {"30 MIB", uint64(30 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 20)), nil},
94 "parse gibibyte (with space)": {"40 GIB", uint64(40 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 30)), nil},
95 "parse tebibyte (with space)": {"50 TIB", uint64(50 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 40)), nil},
96 "parse pebibyte (with space)": {"60 PIB", uint64(60 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 50)), nil},
97
98 "parse byte (with space, lowercase)": {"10 b", uint64(10 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 0)), nil},
99 "parse kibibyte (with space, lowercase)": {"20 kib", uint64(20 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 10)), nil},
100 "parse mebibyte (with space, lowercase)": {"30 mib", uint64(30 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 20)), nil},
101 "parse gibibyte (with space, lowercase)": {"40 gib", uint64(40 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 30)), nil},
102 "parse tebibyte (with space, lowercase)": {"50 tib", uint64(50 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 40)), nil},
103 "parse pebibyte (with space, lowercase)": {"60 pib", uint64(60 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 50)), nil},
104
105 "parse kilobyte": {"20KB", uint64(20 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), nil},
106 "parse megabyte": {"30MB", uint64(30 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), nil},
107 "parse gigabyte": {"40GB", uint64(40 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), nil},
108 "parse terabyte": {"50TB", uint64(50 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), nil},
109 "parse petabyte": {"60PB", uint64(60 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), nil},
110
111 "parse kilobyte (lowercase)": {"20kb", uint64(20 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), nil},
112 "parse megabyte (lowercase)": {"30mb", uint64(30 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), nil},
113 "parse gigabyte (lowercase)": {"40gb", uint64(40 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), nil},
114 "parse terabyte (lowercase)": {"50tb", uint64(50 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), nil},
115 "parse petabyte (lowercase)": {"60pb", uint64(60 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), nil},
116
117 "parse kilobyte (with space)": {"20 KB", uint64(20 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), nil},
118 "parse megabyte (with space)": {"30 MB", uint64(30 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), nil},
119 "parse gigabyte (with space)": {"40 GB", uint64(40 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), nil},
120 "parse terabyte (with space)": {"50 TB", uint64(50 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), nil},
121 "parse petabyte (with space)": {"60 PB", uint64(60 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), nil},
122
123 "parse kilobyte (with space, lowercase)": {"20 kb", uint64(20 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), nil},
124 "parse megabyte (with space, lowercase)": {"30 mb", uint64(30 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), nil},
125 "parse gigabyte (with space, lowercase)": {"40 gb", uint64(40 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), nil},
126 "parse terabyte (with space, lowercase)": {"50 tb", uint64(50 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), nil},
127 "parse petabyte (with space, lowercase)": {"60 pb", uint64(60 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), nil},
128 } {
129 t.Runscip-go gomod github.com/golang/go/src go1.25.0 testing/T#Run().(desc, c.Assertscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseBytesTestCase#Assert().)
130 }
131 }
132
133 func TestFormatBytesscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/TestFormatBytes().(t *testingscip-go gomod github.com/golang/go/src go1.25.0 testing/.Tscip-go gomod github.com/golang/go/src go1.25.0 testing/T#) {
134 for desc, c := range map[string]*FormatBytesTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesTestCase#{
135 "format bytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 0)), "1 B"},
136 "format kilobytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), "1.0 KB"},
137 "format megabytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), "1.0 MB"},
138 "format gigabytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), "1.0 GB"},
139 "format petabytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), "1.0 TB"},
140 "format terabytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), "1.0 PB"},
141
142 "format kilobytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), "1.5 KB"},
143 "format megabytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), "1.5 MB"},
144 "format gigabytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), "1.5 GB"},
145 "format petabytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), "1.5 TB"},
146 "format terabytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), "1.5 PB"},
147
148 "format kilobytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), "1.5 KB"},
149 "format megabytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), "1.5 MB"},
150 "format gigabytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), "1.5 GB"},
151 "format petabytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), "1.5 TB"},
152 "format terabytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), "1.5 PB"},
153
154 "format kilobytes exact": {uint64(1.3 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), "1.3 KB"},
155 "format megabytes exact": {uint64(1.3 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), "1.3 MB"},
156 "format gigabytes exact": {uint64(1.3 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), "1.3 GB"},
157 "format petabytes exact": {uint64(1.3 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), "1.3 TB"},
158 "format terabytes exact": {uint64(1.3 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), "1.3 PB"},
159 } {
160 t.Runscip-go gomod github.com/golang/go/src go1.25.0 testing/T#Run().(desc, c.Assertscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesTestCase#Assert().)
161 }
162 }
163
164 func TestParseByteUnitscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/TestParseByteUnit().(t *testingscip-go gomod github.com/golang/go/src go1.25.0 testing/.Tscip-go gomod github.com/golang/go/src go1.25.0 testing/T#) {
165 for desc, c := range map[string]*ParseByteUnitTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseByteUnitTestCase#{
166 "parse byte": {"B", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 0)), ""},
167 "parse kibibyte": {"KIB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 10)), ""},
168 "parse mebibyte": {"MIB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 20)), ""},
169 "parse gibibyte": {"GIB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 30)), ""},
170 "parse tebibyte": {"TIB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 40)), ""},
171 "parse pebibyte": {"PIB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 50)), ""},
172
173 "parse byte (lowercase)": {"b", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 0)), ""},
174 "parse kibibyte (lowercase)": {"kib", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 10)), ""},
175 "parse mebibyte (lowercase)": {"mib", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 20)), ""},
176 "parse gibibyte (lowercase)": {"gib", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 30)), ""},
177 "parse tebibyte (lowercase)": {"tib", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 40)), ""},
178 "parse pebibyte (lowercase)": {"pib", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 50)), ""},
179
180 "parse byte (with space)": {" B", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 0)), ""},
181 "parse kibibyte (with space)": {" KIB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 10)), ""},
182 "parse mebibyte (with space)": {" MIB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 20)), ""},
183 "parse gibibyte (with space)": {" GIB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 30)), ""},
184 "parse tebibyte (with space)": {" TIB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 40)), ""},
185 "parse pebibyte (with space)": {" PIB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 50)), ""},
186
187 "parse byte (with space, lowercase)": {" b", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 0)), ""},
188 "parse kibibyte (with space, lowercase)": {" kib", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 10)), ""},
189 "parse mebibyte (with space, lowercase)": {" mib", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 20)), ""},
190 "parse gibibyte (with space, lowercase)": {" gib", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 30)), ""},
191 "parse tebibyte (with space, lowercase)": {" tib", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 40)), ""},
192 "parse pebibyte (with space, lowercase)": {" pib", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(2, 50)), ""},
193
194 "parse kilobyte": {"KB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), ""},
195 "parse megabyte": {"MB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), ""},
196 "parse gigabyte": {"GB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), ""},
197 "parse terabyte": {"TB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), ""},
198 "parse petabyte": {"PB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), ""},
199
200 "parse kilobyte (lowercase)": {"kb", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), ""},
201 "parse megabyte (lowercase)": {"mb", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), ""},
202 "parse gigabyte (lowercase)": {"gb", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), ""},
203 "parse terabyte (lowercase)": {"tb", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), ""},
204 "parse petabyte (lowercase)": {"pb", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), ""},
205
206 "parse kilobyte (with space)": {" KB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), ""},
207 "parse megabyte (with space)": {" MB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), ""},
208 "parse gigabyte (with space)": {" GB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), ""},
209 "parse terabyte (with space)": {" TB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), ""},
210 "parse petabyte (with space)": {" PB", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), ""},
211
212 "parse kilobyte (with space, lowercase)": {"kb", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), ""},
213 "parse megabyte (with space, lowercase)": {"mb", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), ""},
214 "parse gigabyte (with space, lowercase)": {"gb", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), ""},
215 "parse terabyte (with space, lowercase)": {"tb", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), ""},
216 "parse petabyte (with space, lowercase)": {"pb", uint64(mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), ""},
217
218 "parse unknown unit": {"imag", 0, "unknown unit: \"imag\""},
219 } {
220 t.Runscip-go gomod github.com/golang/go/src go1.25.0 testing/T#Run().(desc, c.Assertscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/ParseByteUnitTestCase#Assert().)
221 }
222 }
223
224 func TestFormatBytesUnitscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/TestFormatBytesUnit().(t *testingscip-go gomod github.com/golang/go/src go1.25.0 testing/.Tscip-go gomod github.com/golang/go/src go1.25.0 testing/T#) {
225 for desc, c := range map[string]*FormatBytesUnitTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesUnitTestCase#{
226 "format bytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 0)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1"},
227 "format kilobytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1000"},
228 "format megabytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1000000"},
229 "format gigabytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1000000000"},
230 "format petabytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1000000000000"},
231 "format terabytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1000000000000000"},
232
233 "format kilobytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1490"},
234 "format megabytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1490000"},
235 "format gigabytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1490000000"},
236 "format petabytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1490000000000"},
237 "format terabytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1490000000000000"},
238
239 "format kilobytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1510"},
240 "format megabytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1510000"},
241 "format gigabytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1510000000"},
242 "format petabytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1510000000000"},
243 "format terabytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), humanizescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/.Bytescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize`/Byte., "1510000000000000"},
244 } {
245 t.Runscip-go gomod github.com/golang/go/src go1.25.0 testing/T#Run().(desc, c.Assertscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatBytesUnitTestCase#Assert().)
246 }
247 }
248
249 func TestFormateByteRatescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/TestFormateByteRate().(t *testingscip-go gomod github.com/golang/go/src go1.25.0 testing/.Tscip-go gomod github.com/golang/go/src go1.25.0 testing/T#) {
250 for desc, c := range map[string]*FormatByteRateTestCasescip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatByteRateTestCase#{
251 "format bytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 0)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1 B/s"},
252 "format kilobytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.0 KB/s"},
253 "format megabytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.0 MB/s"},
254 "format gigabytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.0 GB/s"},
255 "format petabytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.0 TB/s"},
256 "format terabytes": {uint64(1 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.0 PB/s"},
257
258 "format kilobytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.5 KB/s"},
259 "format megabytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.5 MB/s"},
260 "format gigabytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.5 GB/s"},
261 "format petabytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.5 TB/s"},
262 "format terabytes under": {uint64(1.49 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.5 PB/s"},
263
264 "format kilobytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.5 KB/s"},
265 "format megabytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.5 MB/s"},
266 "format gigabytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.5 GB/s"},
267 "format petabytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.5 TB/s"},
268 "format terabytes over": {uint64(1.51 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.5 PB/s"},
269
270 "format kilobytes exact": {uint64(1.3 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 3)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.3 KB/s"},
271 "format megabytes exact": {uint64(1.3 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 6)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.3 MB/s"},
272 "format gigabytes exact": {uint64(1.3 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 9)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.3 GB/s"},
273 "format petabytes exact": {uint64(1.3 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 12)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.3 TB/s"},
274 "format terabytes exact": {uint64(1.3 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 15)), timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "1.3 PB/s"},
275
276 "format bytes (non-second)": {uint64(10 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 0)), 2 * timescip-go gomod github.com/golang/go/src go1.25.0 time/.Secondscip-go gomod github.com/golang/go/src go1.25.0 time/Second., "5 B/s"},
277 "format bytes (zero-second)": {uint64(10 * mathscip-go gomod github.com/golang/go/src go1.25.0 math/.Powscip-go gomod github.com/golang/go/src go1.25.0 math/Pow().(10, 0)), 0, "10 GB/s"},
278 } {
279 t.Runscip-go gomod github.com/golang/go/src go1.25.0 testing/T#Run().(desc, c.Assertscip-go gomod github.com/git-lfs/git-lfs/v3 . `github.com/git-lfs/git-lfs/v3/tools/humanize_test`/FormatByteRateTestCase#Assert().)
280 }
281 }