Commit Graph

147 Commits

Author SHA1 Message Date
Eric J. Holmes
5dd56998c2 Add failing context.Context test for go1.7. 2016-06-04 15:21:55 +07:00
Matt Silverlock
bd09be08ed [docs] Log ListenAndServe's err response in example 2016-05-25 07:09:13 -07:00
Mukhtar Haji
0d753bb8ca Log ListenAndServe's err response. 2016-05-25 14:44:10 +01:00
Matt Silverlock
9c19ed558d [feature] Add SkipClean option
- SkipClean skips cleaning routes (or a route) - e.g. when true, if the route path is "/path//to", it will remain with the double slash. This is helpful if you have a route like: /fetch/http://xkcd.com/534/
2016-05-02 10:56:24 -07:00
Jingwen Owen Ou
12a13f34e4 go vet is part of Go now 2016-05-02 10:30:24 -07:00
Jingwen Owen Ou
05d9d908e7 Add SkipClean() to *Route 2016-05-02 10:24:47 -07:00
Jingwen Owen Ou
9935257381 Add test for SkipClean 2016-05-02 10:24:18 -07:00
Jingwen Owen Ou
a41434aac3 Clarify more of SkipClean 2016-05-02 10:24:09 -07:00
Matt Silverlock
0eeaf8392f Merge pull request #158 from raninho/master
[tests] old_test: const DefaultRemoteAddr is unused.
v1.1
2016-03-17 14:34:30 -07:00
Raniere Fernandes de Medeiros
8e05c69b5a old_test: const DefaultRemoteAddr is unused. 2016-03-17 18:23:30 -03:00
Matt Silverlock
acf3be1b33 Merge pull request #155 from jprobinson/master
[bugfix] Allow case insensitive regexp groups (fix regression in #144)
2016-03-07 14:01:44 -08:00
JP Robinson
65c2651643 fixing regexp changes from PR #144 2016-03-07 16:38:03 -05:00
Jingwen Owen Ou
786d36e5ab go fmt 2016-03-07 11:43:49 -08:00
Dave Newman
8ac5cf967f Add SkipClean option
By default paths are run through the cleanPath method which prevents
using fancier paths like /fetch/http://xkcd.com/534

This adds a SkipClean option so that this path isn't redirected to
/fetch/http/xkcd.com/534
2016-03-07 11:41:38 -08:00
Matt Silverlock
147a95f5e3 Merge pull request #104 from Digitalxero/method-to-get-url-template
[feature] GetHostTemplate and GetPathTemplate return the template used to build the route.
2016-03-05 05:56:38 -08:00
Dj Gilcrease
f7ac7251e3 Update doc strings based on feedback 2016-02-29 07:54:15 -08:00
Matt Silverlock
c9e326e2bd Merge pull request #150 from gorilla/elithrar/go-lint
[docs] Satisfied golint.

- SkipRouter should also be ErrRouterSkipped (or similar) but a change would break the public API.
2016-02-28 19:40:56 -08:00
Matt Silverlock
02c98b3f73 [docs] Satisfied golint.
- SkipRouter should also be ErrRouterSkipped (or similar) but a change would
  break the public API.
2016-02-28 19:32:22 -08:00
Dj Gilcrease
f84ab9ab62 Fix go fmt issues 2016-02-28 14:46:18 -08:00
Dj Gilcrease
0d60c4bfeb Add tests for GetPathTemplate. Added GetHostTemplate and associated tests as well 2016-02-28 14:42:09 -08:00
Dj Gilcrease
16507e2c47 Merge branch 'master' into method-to-get-url-template 2016-02-28 13:16:25 -08:00
Matt Silverlock
c582f4facc Merge pull request #149 from gorilla/elithrar/readme-website
[docs] Add http://www.gorillatoolkit.org/pkg/mux to README.
2016-02-28 12:29:58 -08:00
Matt Silverlock
5f42f0f524 [docs] Add http://www.gorillatoolkit.org/pkg/mux to README. 2016-02-28 12:25:42 -08:00
Matt Silverlock
d067e87329 Merge pull request #144 from tumdum/regexp-speedup
[refactor] Only wrap regexp in group if not already in a group + perf. gains.

- Addresses https://github.com/gorilla/mux/issues/62
- ~27% less allocs/~15% speedup (ns/op)
2016-02-28 12:22:47 -08:00
Matt Silverlock
dfc482b255 Merge pull request #148 from gorilla/ci/travis-go-1.6
[ci] Update .travis.yml to build Go 1.6
2016-02-26 13:29:39 -08:00
Matt Silverlock
7872f90afa Update .travis.yml to build Go 1.6 2016-02-26 13:23:39 -08:00
Tomasz Kłak
78fb8eb962 Added benchmark with deep path 2016-01-23 18:09:52 +01:00
Tomasz Kłak
f48927253f Named groups replaced with conditional wrapping of regexps 2016-01-23 17:42:00 +01:00
Matt Silverlock
26a6070f84 Merge pull request #141 from tcyrus/patch-1
[docs] Tidy up README formatting.
2015-12-31 08:19:08 -08:00
Timothy Cyrus
66181ed337 Update README.md 2015-12-31 11:12:17 -05:00
Matt Silverlock
2aad27d310 Merge pull request #139 from bign8/issue_20
[feature] NotFoundHandler on Subrouters is now called correctly.
2015-12-29 14:32:19 +08:00
Nate Woods
82a9c170d4 Covering change with unit test
This test focuses on the feature of allowing sub-routers error handlers to precede the parents, rather than the code change required to provide this functionality.
2015-12-26 00:09:25 -07:00
bign8
c329c7d193 Potential fix for #20 2015-12-25 13:18:57 -07:00
Matt Silverlock
9c068cf16d Merge pull request #134 from shurcooL/travis-CI-more-thorough
[ci] Perform gofmt, go vet checks; use race detector during tests.
2015-11-11 18:35:30 +08:00
Dmitri Shuralyov
9a9f155278 Travis: Perform gofmt, go vet checks; use race detector during tests.
This change augments the Travis CI build to perform:

- Check that all files follow gofmt style, including -s (simplify) option.
- Check that go vet does not report any problems.
- Use race detector when running tests, to ensure there are no data races found.
2015-11-08 17:29:33 -08:00
Matt Silverlock
48e889f422 Merge pull request #133 from mttrs/govet
[test] Correct a printf verb type
2015-11-08 13:16:49 +08:00
mitsuteru sawa
a90bbbc6fa Correct a printf verb type
% go vet
mux_test.go:1080: arg len(ancestors) for printf verb %s of wrong type:
int
2015-11-07 21:34:30 +09:00
Matt Silverlock
ad4d7a5882 Merge pull request #128 from mcasper/typo
[docs] Add docs to private functions; fix typo.
2015-10-03 15:26:51 +08:00
Matt Casper
ac3897eae3 Fix a typo in the comments, add a few comment docs 2015-10-03 00:21:00 -07:00
Kamil Kisiel
49c0242755 Merge pull request #125 from eastwood/develop
Fixed documentation from Issue 16
2015-09-08 09:58:39 -07:00
Clint Ryan
8ae7a23e03 Fixed documentation from Issue 16 2015-09-08 21:31:30 +10:00
Kamil Kisiel
ee1815431e Update .travis.yml 2015-08-19 22:15:06 -07:00
Kamil Kisiel
f8220e087d travis-ci: more recent go versions 2015-08-16 00:31:34 -07:00
Matt Silverlock
f7b6aaaa69 Merge pull request #122 from gorilla/README-badge-fix
Fixed GoDoc badge.
2015-08-14 22:29:16 +08:00
Matt Silverlock
e45852e537 Fixed GoDoc badge. 2015-08-14 22:25:16 +08:00
Kamil Kisiel
b0b2bc47bc Quote domain names in README.md. Use example.com instead of domain.com
Fixes #119
2015-08-13 12:01:04 -07:00
Kamil Kisiel
5112c33f3a slightly improve printing of regexps in failed tests. 2015-08-11 22:16:39 -07:00
Kamil Kisiel
e330fd08a3 Merge pull request #120 from shkw/reduce-variable-name-restriction
Reduce variable name restriction
2015-08-10 22:40:28 -07:00
Shinya Kawaguchi
d17b93cab8 Refactoring for better performance 2015-08-11 14:26:09 +09:00
Shinya Kawaguchi
273db68971 Fix regexp syntax error caused by variable names containing any characters except letters, digits, and underscores 2015-08-11 04:32:47 +09:00