[PDB-1017] Node tests broken due to bug in assertion code Created: 2014/11/06  Updated: 2015/11/30  Resolved: 2014/11/19

Status: Closed
Project: PuppetDB
Component/s: None
Affects Version/s: None
Fix Version/s: PDB 2.3.0

Type: Bug Priority: Normal
Reporter: Ryan Senior Assignee: Ryan Senior
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template:
Story Points: 1
Sprint: PuppetDB 2014-12-03

 Description   

While looking into another issue, I found two issues related to our node-query tests, specifically here: https://github.com/puppetlabs/puppetdb/blob/master/test/puppetlabs/puppetdb/http/nodes_test.clj#L65. There are tests in that namespace that actually generate incorrect SQL, I see a stacktrace in standard error, but the error isn't returned and PuppetDB is actually responding with a 200 and an empty body. The empty body causes the doseq above to be skipped, and since the response is 200, the test runs successfully, even though there was a failure and no results were returned.

We should also look into our bad handling of this failed query. Ideally it should be returning a 4xx error, but certainly shouldn't return a 200.


Generated at Thu Aug 22 11:39:41 PDT 2019 using JIRA 7.7.1#77002-sha1:e75ca93d5574d9409c0630b81c894d9065296414.