Adrien Marquès
017bfd45b4
test multipart body paramters
2019-11-21 23:23:04 +01:00
Adrien Marquès
635773218f
make internal/multipart use internal/cerr constant errors
...
continuous-integration/drone/push Build is passing
Details
- instead of defining its own
2019-11-21 22:35:00 +01:00
Adrien Marquès
0126a551b3
Merge branch 'test/internal' of go/aicra into 0.2.0
continuous-integration/drone/push Build is passing
Details
2019-11-21 21:31:24 +00:00
Adrien Marquès
4221f8cf2c
test internal/config trick to have a 100% coverage (as conflict check is undeterministic, merge all conditions)
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/pr Build is passing
Details
2019-11-21 22:29:58 +01:00
Adrien Marquès
8ba58b4748
test internal/config empty parameter rename should not rename
2019-11-21 22:27:57 +01:00
Adrien Marquès
b18ea98497
remove dead code
2019-11-21 22:20:12 +01:00
Adrien Marquès
6218327fd2
expand internal/config test coverage
...
- make parameter type "?" invalid as it marks it as optional only
- check optional vs. required parameters
- test subservice in method description error check
2019-11-21 22:18:00 +01:00
Adrien Marquès
8cebf52405
add internal/config test for the Browse() method
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/pr Build is passing
Details
2019-11-21 22:00:48 +01:00
Adrien Marquès
aada9edff5
test internal/config parsing and illegal/missing fields
2019-11-21 21:48:24 +01:00
Adrien Marquès
52b42e479a
parameter name conflict: on rename conflicting rename, return original name
2019-11-21 21:34:25 +01:00
Adrien Marquès
19e203c364
refactor internal/config
...
- create cerr (constant errors) with wrapped context (service name, method, parameter name)
- fix comments numbering
- remove duplicate check
2019-11-21 21:29:23 +01:00
Adrien Marquès
28d11b840f
test internal/cerr package + add WrapString() to use a raw string
continuous-integration/drone/push Build is passing
Details
2019-11-21 20:51:29 +01:00
Adrien Marquès
a173ab6c4c
fix typo
continuous-integration/drone/push Build is passing
Details
2019-11-19 19:25:38 +01:00
Adrien Marquès
fa6ae714b6
fix readme usage & changelog
continuous-integration/drone/push Build is passing
Details
2019-11-19 19:24:57 +01:00
Adrien Marquès
d17a82f47a
Prettify logs
continuous-integration/drone/push Build is passing
Details
2019-11-19 19:19:55 +01:00
Adrien Marquès
ca5d013a64
Merge branch 'refactor/reqdata' of go/aicra into 0.2.0
continuous-integration/drone/push Build is passing
Details
2019-11-19 16:09:33 +00:00
Adrien Marquès
a54c428670
Test json: add a check with invalid json (no parameter is parsed)
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/pr Build is passing
Details
2019-11-19 17:00:11 +01:00
Adrien Marquès
0a470dbd40
Test json body parameters
continuous-integration/drone/push Build is passing
Details
2019-11-19 16:57:23 +01:00
Adrien Marquès
24b0eaa68b
Test with url encoded body parameters
2019-11-19 16:53:02 +01:00
Adrien Marquès
da1ee37612
Test store agains Query parameters
continuous-integration/drone/push Build is passing
Details
2019-11-19 16:18:56 +01:00
Adrien Marquès
f272f880e8
Test store with uri arguments
2019-11-19 16:18:50 +01:00
Adrien Marquès
36008db9e5
Test empty store -> fix
2019-11-19 16:18:45 +01:00
Adrien Marquès
8a1144a187
merge parseParameter
2019-11-19 16:18:27 +01:00
Adrien Marquès
f247581395
fix badge
continuous-integration/drone/push Build is passing
Details
2019-11-19 16:16:42 +01:00
Adrien Marquès
97de8a1f28
remove jenkins support
2019-11-19 16:16:42 +01:00
Adrien Marquès
60a1849cf8
add builtin.bool test + make other types that allow 'string' allow '[]byte' as well
2019-11-19 16:16:42 +01:00
Adrien Marquès
9affef4cd7
add ci support
2019-11-19 16:16:42 +01:00
Adrien Marquès
712c047096
add startup logs
...
Log aicra configuration 'METHOD /PATH' when creating the instance
Log mapped handlers before starting listening
To know when we start listening (was transparently handled by http.ListenAndServer) ; added a wrapper around 'Server' (i.e. httpServer) that fulfills the http.Server interface
2019-11-19 16:16:42 +01:00
Adrien Marquès
aa9ef778eb
Update readme
2019-11-19 16:16:42 +01:00
Adrien Marquès
9bf7f24ec9
feat: typechecks: tests for 'float64'
2019-11-19 16:16:42 +01:00
Adrien Marquès
4c5f13933c
feat: typechecks: tests for 'uint' + add string repr for 'int'
2019-05-06 18:34:21 +02:00
Adrien Marquès
4e36adfcc9
readme: add ci badge
2019-05-06 18:34:21 +02:00
Adrien Marquès
f53dfcbf62
ci: create jenkins file
2019-05-06 18:34:11 +02:00
Adrien Marquès
be84c86172
fix: use t.Run in tests instead of for{} with i
2019-05-05 19:01:54 +02:00
Adrien Marquès
21f48a65ee
feat: parallelize tests +ci
2019-05-05 19:01:54 +02:00
Adrien Marquès
bf3e651c2c
ref: clean comments and make errors constants
2019-05-05 19:01:54 +02:00
Adrien Marquès
0780e8dd33
feat: update string type checker | test: string, int, float, any typecheckers
...
feat: string type checker pre-process min,max/fixed length(s) before returning the CheckerFunc
feat: add typecheckers for 'any', 'float' and 'int' (managing number overflows)
2019-05-05 19:01:54 +02:00
Adrien Marquès
bafaad97e6
clean: request param now uses internal const error 'cerr'
2019-05-05 19:01:54 +02:00
Adrien Marquès
a83d077569
feat: add builtin types [int, uint] | fix request param getters | add request param getters [GetFloat, GetInt, GetUint, GetStrings] with permissive possible types and 'automatic' conversion
2019-05-05 19:01:54 +02:00
Adrien Marquès
eb5ce4c0d0
fix: semantic renaming : internal.config.Method.Permission is now Scope
2019-05-05 19:01:54 +02:00
Adrien Marquès
189d3b40a6
fix: semantic (comments) renaming : 'controller' to 'service', more explicit names
2019-05-05 19:01:54 +02:00
Adrien Marquès
6afedf190f
ref 1: clean server.go code + response implements http.Handler + add generic getter on request params Get() (interface{},error)
2019-05-05 19:01:54 +02:00
Adrien Marquès
0e498607ba
clean
2019-05-05 19:01:54 +02:00
Adrien Marquès
0912e07f4f
fix: pass error arguments as values not array + set header after
...
WriteHeader()
2019-05-05 19:01:54 +02:00
Adrien Marquès
7a87288876
fix: rename 'WrapError' to 'SetError' + shadow response error + response implements Error()
2019-05-05 19:01:54 +02:00
Adrien Marquès
1e4476ced5
feat: rename 'Error.Put' to 'SetArguments' with n >= 1 arguments + move 'WrapError' to response
2019-05-05 19:01:54 +02:00
Adrien Marquès
b9ca1801bd
fix: rename 'NewError' to 'WrapError'
2019-05-05 19:01:54 +02:00
Adrien Marquès
b9f240b86b
feat: fix error creation to bind arguments directly + add optional error argument in NewResponse()
2019-05-05 19:01:54 +02:00
Adrien Marquès
4e25c647b2
feat: add status code in response
2019-05-01 16:40:26 +02:00
Adrien Marquès
d0f5277bf4
fix: prefix service path with '/' if missing
2019-05-01 16:28:16 +02:00