- init
continuous-integration/drone/push Build is passing Details
continuous-integration/drone/tag Build is passing Details

master v1.0.0
李光春 2 years ago
commit 3601ccf4f5

@ -0,0 +1,17 @@
kind: pipeline
type: docker
name: clone
steps:
- name: Test
image: golang:1.18
commands:
- go env -w GO111MODULE=on
- go env -w GOPROXY=https://goproxy.cn,direct
- go test -v ./...
- name: Benchmark
image: golang:1.18
commands:
- go env -w GO111MODULE=on
- go env -w GOPROXY=https://goproxy.cn,direct
- go test -bench=. -benchmem

9
.gitignore vendored

@ -0,0 +1,9 @@
.env
.git
.svn
.idea
.vscode
*.log
goinit.sh
gomod.sh
/vendor/

@ -0,0 +1,3 @@
module go.dtapp.net/goint
go 1.18

@ -0,0 +1,16 @@
package goint
import (
"math"
"strconv"
)
// ToString int到string
func ToString(n int) string {
return strconv.Itoa(n)
}
// ToFloat64 int到float64
func ToFloat64(n int) float64 {
return float64(n) / math.Pow10(0)
}

@ -0,0 +1,13 @@
package goint
import (
"testing"
)
func TestToString(t *testing.T) {
t.Log(ToString(9898))
}
func TestToFloat64(t *testing.T) {
t.Log(ToFloat64(9898))
}

@ -0,0 +1,3 @@
package goint
const Version = "1.0.0"

@ -0,0 +1,7 @@
package goint
import "testing"
func TestVersion(t *testing.T) {
t.Log(Version)
}
Loading…
Cancel
Save