Robert Vollmert and Steve Chavez
60b64d3e81
Upgrade hspec-wai dependency to 0.10.
2020-03-07 13:04:17 -05:00
Robert and Steve Chávez
afb7266f17
Update jose to 0.8.1 to fix Windows build (and adapt error message test) ( #1351 )
2019-07-15 15:14:22 +00:00
Robert and Steve Chávez
617bf7b6a3
Update jose to 0.8 (and adapt error message test) ( #1324 )
...
The message changes between jose versions 0.7 and 0.8.
2019-07-04 10:56:45 -05:00
Xavier Francisco and Steve Chávez
28b3d6cafd
Update stylish haskell config; apply all; add CI config ( #1299 )
...
* Update config default; Copy non-defaults
* Update .stylish-haskell config version to match pgrst
* Apply stylish haskell to all files
* CircleCI config
* Remove redundant import.
What is used from Network.HTTP.Types.Headers is also exported by Network.HTTP.Types.
* Grouped imports
* Show un-styled files on CircleCI failure
* Fix styling imports
* Apply adhoc standard correctly
2019-05-23 10:44:34 -05:00
Xavier Francisco and Steve Chávez
32725f2f35
Fix tests expected responses due to changes in pg11 ( #1268 )
2019-04-07 19:03:02 -05:00
Steve Chávez and Joe Nelson
4ba27d84a4
Fix some OpenAPI issues ( #970 )
...
* Fix #933 , update externals docs url to current version
* Fix #962 , openApi don't err on nonexistent schema
* Fix #954 , make OpenAPI rpc output dependent on user privileges
2017-09-25 23:09:52 -07:00
Joe Nelson and GitHub
0ed4215a0d
Support asymmetric JWK ( #919 )
2017-08-09 08:42:00 -05:00
Joe Nelson and GitHub
50de0536de
Allow csv formatting in rpc output ( #882 )
2017-05-27 00:07:23 -05:00
Diogo Biazus and Joe Nelson
728e40c96c
Update hspec-wai to 0.8.0 ( #799 )
2017-02-14 21:18:01 -08:00
Joe Nelson and GitHub
104a7ed4fa
Use a mime type to request singular JSON responses ( #763 )
2017-01-16 15:11:37 -08:00
Joe Nelson and GitHub
74e68408e6
Bring packages up to date ( #722 )
...
* Bring packages up to date
* New LTS includes deps now
Use stack to select most versions
* Alphabetize packages
* Strip down packages
Switch tests to protolude
* Appease cabal check with base version constraint
2016-10-19 22:25:58 -07:00
Joe Nelson
5a166e8e80
Fix custom pre-request handler
...
Uses Ruslan's technique
2016-09-27 23:17:08 -07:00
Joe Nelson
06363ccc77
WIP: add argument for custom pre-request handler
2016-09-27 00:19:05 -07:00
Joe Nelson
12a8c682bd
Use sql to generate jwt, rather than custom haskell
2016-09-24 21:32:47 -07:00
Joe Nelson
7bf5b0106d
Semantic WWW-Authenticate headers for problematic JWT
...
Adapting an OAuth 2.0 convention from RFC 6750 for use with JWT
2016-09-24 21:28:08 -07:00
Joe Nelson
fb5fce026d
Issue http 401 for expired jwt
...
Fixes #512
2016-09-24 21:28:08 -07:00
Joe Nelson
18e3c30ad8
Return proper 401/403 when access denied
...
Fixes #584
2016-05-15 00:56:47 -07:00
Joe Nelson
b858626e17
For correctness include charset=utf-8 in responses
2016-03-13 14:22:17 -07:00
Joe Nelson
f67e195f76
Expose all claims via sql postgrest.claims
2016-03-11 20:51:22 -08:00
Joe Nelson
508d722fb2
Allow SQL functions to generate registered JWT claims
2016-03-10 21:58:43 -08:00
Joe Nelson
d7fe59f0b0
WIP: share server code between tests and program
...
- Share server code in Main
- Switch to hasql-pool
- Use pool in tests
- DRY up test runner
2016-02-21 12:22:18 -08:00
Joe Nelson
b9fd083c77
It all compiles but all requests give a postgres error
2016-01-24 18:09:19 -08:00
Joe Nelson
fec316b087
WIP: fixing compiler errors in specs
2016-01-24 18:09:19 -08:00
Joe Nelson
b3144aee15
Cache schema structure between tests for speed
...
Causes one test to fail
2015-12-10 13:36:28 -08:00
Diogo Biazus
0961524e70
Refactors tests to use new fixtures and remove some haskell functions that wont be necessary anymore
2015-12-08 00:44:49 -05:00
Joe Nelson
f4c73c7666
Test for --max-rows behavior
2015-12-05 19:31:53 -08:00
calebmer
aab2f0d1f1
Ensure JWT expires
2015-11-05 17:04:54 -05:00
Diogo Biazus
91dfd47f1d
Adds another test case for jwt with empty claims
2015-10-22 23:20:16 -04:00
Diogo Biazus
aad19b53c7
Includes one test case for recovering from from 400 error and another for invalid JWT tokens
2015-10-22 23:12:14 -04:00
Diogo Biazus
81ee7cbd5e
Removes redundant do
2015-10-20 19:54:29 -04:00
Diogo Biazus
a192cadced
All green :D
2015-10-20 19:23:12 -04:00
calebmer
8e107e5b24
Tolerate missing role in user creation
2015-10-07 20:01:46 -04:00
Joe Nelson
480800edbd
Problem after exceptions when authed
...
Reproduces #264
2015-08-26 20:49:23 -07:00
Federico Rampazzo
77aecc9e86
JWT support
2015-05-20 06:01:50 +01:00
Joe Nelson
e37d5d9b25
Style tweak
2015-02-15 15:59:49 -08:00
Joe Nelson
f06f3e3394
Isolate tests
...
Credentials from AuthSpec were interfering with StructureSpec
2015-01-31 11:32:08 -08:00
Adam C. Baker
c9b960f955
only create schema once
2014-12-29 17:57:31 -08:00
Adam C. Baker
2ae99daa12
resetDb once for each set of tests.
2014-12-29 17:57:31 -08:00
Joe Nelson
f689ce684a
Provide proper JSON details for errors
...
Refines HTTP codes for server vs client problems
Fixes #92
Fixes #40
2014-12-21 19:34:21 -08:00
Joe Nelson
dbe1f59066
Update project name in strings
...
Fixes #105
2014-12-17 10:24:24 -08:00
Joe Nelson
7d58097449
Be sure to reset db before ALL tests
2014-12-06 17:42:42 -08:00
Joe Nelson
f6b7b42d75
Feature specs compile
2014-12-06 17:42:20 -08:00
Adam C. Baker
74855db87b
declare required extensions
...
and remove default extension pragmas (OverloadedStrings)
2014-11-05 00:32:10 -08:00
Joe Nelson
572c235b79
Add /dbapi/users route for creating new user
2014-10-21 15:01:04 -07:00
Joe Nelson
9c84cf9c3d
Fix lint warnings
2014-10-13 18:16:41 -07:00
Adam C. Baker
fd237b33b1
fix/unpend tests.
2014-10-13 16:54:21 -07:00
Joe Nelson
b52af7ac66
Make tests pending and revisit after Friday deadline
2014-10-08 14:58:38 -07:00
Joe Nelson
527d51670c
WIP: Trap postgres errors in middleware
...
Fixes #39
2014-10-08 14:58:38 -07:00
Joe Nelson
68d0a38806
WIP: feature specs for auth
2014-10-08 14:48:31 -07:00