Search tickets ============== `distix list` lets the user limit the list of tickets it shows using a query language. For now, the search language is very simplistic: it only allows a query of the form `foo!=bar`, where `foo` and `bar` form a key/value pair and the query matches if `foo` does __not__ have a value `bar`. This is useful for listing open tickets: `distix list state!=closed`. Tickets do not, by default, have a `state` key, but they can be marked closed by setting one. The search language will be improved later. The purpose of the simple approach is to get `distix` into a form that can be used for real in real projects as soon as possible. SCENARIO list finds only open tickets First, create two tickets with different titles. WHEN user attempts to run distix init REPO THEN attempt succeeded WHEN user changes working directory to REPO AND user attempts to run distix new first-ticket --save-ticket-id=../T1 THEN attempt succeeded WHEN user attempts to run distix new second-ticket --save-ticket-id=../T2 THEN attempt succeeded Make sure `distix list` shows both tickets. WHEN user attempts to run distix list THEN attempt succeeded AND output matches "first-ticket" AND output matches "second-ticket" Set the second ticket's state to closed, and make sure `distix list` still shows both tickets. WHEN user attempts to run ... distix set --ticket-id-from=../T2 state=closed DUMMY THEN attempt succeeded WHEN user attempts to run distix list THEN attempt succeeded AND output matches "first-ticket" AND output matches "second-ticket" However, if we search for open tickets, only the first ticket should be listed. WHEN user attempts to run distix list state!=closed THEN attempt succeeded AND output matches "first-ticket" AND output doesn't match "second-ticket"