summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKurt <kurt.w.jung@gmail.com>2016-11-11 21:44:09 -0500
committerKurt <kurt.w.jung@gmail.com>2016-11-11 21:44:09 -0500
commit83f63e773b4dd5516af63ba8d7278e21f96f2062 (patch)
tree68060ea62f0ac8e2eabc9f3a71a4231652a0ee9a
parentf51ce6c2fb4179749a4e048b51701ecff7e31add (diff)
Adjust some names of test functions to conform with Go's naming conventions
-rwxr-xr-xcheck2
-rw-r--r--contrib/barcode/barcode.go8
-rw-r--r--contrib/tiff/tiff_test.go2
-rw-r--r--fpdf_test.go6
4 files changed, 10 insertions, 8 deletions
diff --git a/check b/check
new file mode 100755
index 0000000..9492e43
--- /dev/null
+++ b/check
@@ -0,0 +1,2 @@
+go tool vet -all .
+gofmt -s -l .
diff --git a/contrib/barcode/barcode.go b/contrib/barcode/barcode.go
index 8fb371e..0649564 100644
--- a/contrib/barcode/barcode.go
+++ b/contrib/barcode/barcode.go
@@ -20,10 +20,6 @@ package barcode
import (
"bytes"
"errors"
- "image/jpeg"
- "io"
- "strconv"
- "sync"
"github.com/boombuler/barcode"
"github.com/boombuler/barcode/codabar"
"github.com/boombuler/barcode/code128"
@@ -34,6 +30,10 @@ import (
"github.com/boombuler/barcode/twooffive"
"github.com/jung-kurt/gofpdf"
"github.com/ruudk/golang-pdf417"
+ "image/jpeg"
+ "io"
+ "strconv"
+ "sync"
)
// barcodes represents the barcodes that have been registered through this
diff --git a/contrib/tiff/tiff_test.go b/contrib/tiff/tiff_test.go
index 28163a0..d222375 100644
--- a/contrib/tiff/tiff_test.go
+++ b/contrib/tiff/tiff_test.go
@@ -6,7 +6,7 @@ import (
"github.com/jung-kurt/gofpdf/internal/example"
)
-func ExampleTiff() {
+func ExampleRegisterFile() {
pdf := gofpdf.New("L", "mm", "A4", "")
pdf.SetFont("Helvetica", "", 12)
pdf.SetFillColor(200, 200, 220)
diff --git a/fpdf_test.go b/fpdf_test.go
index 9f99568..09346ff 100644
--- a/fpdf_test.go
+++ b/fpdf_test.go
@@ -1764,7 +1764,7 @@ func ExampleFpdf_AddFontFromBytes() {
}
// This example demonstrate Clipped table cells
-func ExampleFpdf_ClippedTableCells() {
+func ExampleFpdf_ClipRect() {
marginCell := 2. // margin of top/bottom of cell
pdf := gofpdf.New("P", "mm", "A4", "")
pdf.SetFont("Arial", "", 12)
@@ -1806,8 +1806,8 @@ func ExampleFpdf_ClippedTableCells() {
// Successfully generated pdf/Fpdf_ClippedTableCells.pdf
}
-// This example demonstrate Wrapped table cells
-func ExampleFpdf_WrappedTableCells() {
+// This example demonstrate wrapped table cells
+func ExampleFpdf_Rect() {
marginCell := 2. // margin of top/bottom of cell
pdf := gofpdf.New("P", "mm", "A4", "")
pdf.SetFont("Arial", "", 12)