Adam Townsend
b56b618a8c
added stages to build a deliverable and then clean it up when done
2023-10-16 10:50:22 -07:00
Adam Townsend
5631ae386f
include rackup
2023-10-13 21:28:47 -07:00
Adam Townsend
c31c556df5
removed falcon and it's dependencies, because it wasn't working right.
...
use puma for now
2023-10-13 21:27:25 -07:00
bucky
5fae0c4fa9
Merge pull request 'rspec-coverage' ( #22 ) from rspec-coverage into master
...
Reviewed-on: #22
2023-10-12 23:49:48 -07:00
Adam Townsend
144731062b
added URL validation to webpage part
2023-10-12 23:42:52 -07:00
Adam Townsend
72f3e03edd
added tests for invalid URL entries
...
+ URL that returns a 404
+ URL where the domain does not resolve with DNS
+ URL that is not properly formatted
2023-10-12 23:42:04 -07:00
Adam Townsend
b08693e866
remove the puts, don't print out the test result
2023-10-12 23:41:38 -07:00
Adam Townsend
ae2360a480
include the proper status code
2023-10-12 23:31:15 -07:00
Adam Townsend
213265a5d0
added test for submitting with the wrong content type header
2023-10-12 23:30:47 -07:00
Adam Townsend
dfb6b23e70
run simplecov for rspec tests
2023-10-12 23:12:14 -07:00
Adam Townsend
c81a7a6160
added rescue for urls that don't resolve
2023-10-12 19:03:03 -07:00
Adam Townsend
bbb710a5e1
added test for bad TLD, better named 404 url test
2023-10-12 19:02:38 -07:00
Adam Townsend
7eaa8eacf8
added rescue for OpenURI HTTPErrors
2023-10-12 18:26:13 -07:00
Adam Townsend
d78e361c29
added test for validating a url is accessible
2023-10-12 18:25:38 -07:00
Adam Townsend
1ae6c02472
rescue BadURIError for invalid URL format
2023-10-12 18:20:56 -07:00
Adam Townsend
11206854ad
added test for an invalid url
2023-10-12 18:20:35 -07:00
Adam Townsend
33089e6fbd
build HTML output with cucumber and rspec files in root dir
2023-10-12 16:25:22 -07:00
bucky
5cec47efcc
Merge pull request 'create-json' ( #21 ) from create-json into master
...
Reviewed-on: #21
2023-10-12 14:36:38 -07:00
Adam Townsend
cabb4daded
split up the nil? and empty? cases, because they are different
...
situations
2023-10-12 14:27:31 -07:00
Adam Townsend
1e61a76ded
added 2 more tests for empty and missing url data posting to links
2023-10-12 14:27:02 -07:00
Adam Townsend
ac3e9f14cd
added links route for API interactions
2023-10-12 11:42:43 -07:00
Adam Townsend
5ee9351362
added db initialization to make sure the db exists and is up to date
...
before tests
2023-10-12 11:42:14 -07:00
Adam Townsend
2964e06639
added before and after actions
...
+ before initializes the db
+ after cleans the db
2023-10-12 11:40:15 -07:00
Adam Townsend
d1a0fc0222
change request to use the /links path, to fit more into a RESTful API
...
format
+ also renamed the test to better describe the behavior
2023-10-12 11:32:00 -07:00
Adam Townsend
4a82174526
implemented API create endpoint
...
+ added plugins to read json and access the header to parse the request
for an API request
+ fixed logic where url param is nil
+ refactored the new code to a variable to be reused easier
+ if CONTENT_TYPE header is application/json, reply with json
- there could be more refactoring (maybe separating it to a different
endpoint) to handle other scenarios, we'll work on that later
2023-10-11 19:21:43 -07:00
Adam Townsend
3ae20255f6
DRY it out a little
2023-10-11 19:21:21 -07:00
Adam Townsend
f69c53bf29
removed unnecessary variable
2023-10-11 19:20:07 -07:00
Adam Townsend
7d6c098047
added more to the spec test for creating a new link
2023-10-11 19:18:47 -07:00
Adam Townsend
3421e18f21
added more logic for running tests without killing the whole pipeline, and outputting rspec results
2023-10-11 12:05:33 -07:00
Adam Townsend
0dec27a01c
added rspec step in tests stage, adjusted should clause
2023-10-11 11:04:08 -07:00
Adam Townsend
c45cf6ab51
started building out rspec specs for API functionality
2023-10-11 11:01:46 -07:00
Adam Townsend
e50667b392
split homepage out into homepage and submit feature sets
2023-10-10 17:29:23 -07:00
bucky
d4db64f404
Merge pull request 'cucumber-jenkins' ( #20 ) from cucumber-jenkins into master
...
Reviewed-on: #20
2023-10-10 17:22:55 -07:00
Adam Townsend
05858078d1
added unstable scenario
2023-10-10 17:20:25 -07:00
Adam Townsend
f75f0378bf
separate out success and failure tasks
2023-10-10 17:16:24 -07:00
Adam Townsend
c3d2fb32e2
added icon for message
2023-10-10 17:11:05 -07:00
Adam Townsend
1fe30fc7e7
removed jenkins cucumber section, use the html formatter instead
...
also added more info to the success message
2023-10-10 17:05:33 -07:00
Adam Townsend
43cc151138
moved stuff around a little more
2023-10-10 14:50:01 -07:00
Adam Townsend
1fee4f276d
maybe put both files in the same report
2023-10-10 14:47:09 -07:00
Adam Townsend
0b17f36fde
added more test results, just exploring
2023-10-10 14:43:11 -07:00
Adam Townsend
aca92fdae1
cleaned up message a bit for success
2023-10-10 14:32:54 -07:00
Adam Townsend
c7bf62062a
wrap it
2023-10-10 14:28:41 -07:00
Adam Townsend
b853ca6fe4
trying to make the message cleaner, and print the env to take a look at other options
2023-10-10 14:25:59 -07:00
Adam Townsend
d5919fc82a
got it working with vars, now try the URLs
2023-10-10 14:23:44 -07:00
Adam Townsend
e2395989f4
try normal quotes
2023-10-10 14:22:30 -07:00
Adam Townsend
e93868a483
try DB_NAME since the others are failing
2023-10-10 14:19:59 -07:00
Adam Townsend
7f6fc24872
maybe this one will work
2023-10-10 14:17:48 -07:00
Adam Townsend
776ec0d30d
trying different env vars
2023-10-10 14:10:50 -07:00
Adam Townsend
6861740d00
bots can't be easily used with incoming webhooks, but let's try some URLs
2023-10-10 14:05:18 -07:00
Adam Townsend
77e72d18e1
use the bot's endpoint
2023-10-10 13:50:48 -07:00