Skip to content
This repository has been archived by the owner on May 14, 2023. It is now read-only.

Commit

Permalink
Add transform examples
Browse files Browse the repository at this point in the history
  • Loading branch information
jdkato committed Oct 3, 2017
1 parent 2560582 commit 20d3663
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions transform/transform_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,38 @@ func ExampleNewTitleConverter() {
fmt.Println(tc.Title("the last of the mohicans"))
// Output: The Last of the Mohicans
}

func ExampleSimple() {
fmt.Println(Simple("test string"))
// Output: test string
}

func ExampleDash() {
fmt.Println(Dash("test string"))
// Output: test-string
}

func ExampleSnake() {
fmt.Println(Snake("test string"))
// Output: test_string
}

func ExampleDot() {
fmt.Println(Dot("test string"))
// Output: test.string
}

func ExampleConstant() {
fmt.Println(Constant("test string"))
// Output: TEST_STRING
}

func ExamplePascal() {
fmt.Println(Pascal("test string"))
// Output: TestString
}

func ExampleCamel() {
fmt.Println(Camel("test string"))
// Output: testString
}

0 comments on commit 20d3663

Please sign in to comment.