Detailed Description
A cloud-only pipeline, so the Cloud Request Engine is the only element and its accepted Evidence is the list the stand-in service gives, which holds query.User-Agent alone.
Everything else is Evidence no element in the pipeline accepts, and the engine still sends it.
Inheritance diagram for tests.test_all_evidence_sent.TestAllEvidenceSent:
Collaboration diagram for tests.test_all_evidence_sent.TestAllEvidenceSent:
Public Member Functions | |
| send (self, evidence, settings=None) | |
| test_evidence_the_service_does_not_list_is_sent (self) | |
| test_evidence_the_service_lists_is_still_sent (self) | |
| test_query_evidence_wins_whether_listed_or_not (self) | |
| test_each_prefix_wins_over_every_later_one (self) | |
| test_a_prefix_ranks_the_same_in_any_letter_case (self) | |
| test_other_prefixes_rank_by_the_prefix_alone (self) | |
| test_a_reserved_name_is_never_sent_from_evidence (self) | |
| test_the_web_request_view_is_never_sent (self) | |
| test_a_reserved_name_is_left_out_under_any_prefix_and_case (self) | |
| test_the_name_sent_is_everything_after_the_first_dot (self) | |
| test_the_name_sent_keeps_the_letter_case_given (self) | |
| test_one_name_in_two_letter_cases_is_sent_once (self) | |
Member Function Documentation
◆ send()
| tests.test_all_evidence_sent.TestAllEvidenceSent.send | ( | self, | |
| evidence, | |||
| settings = None ) |
Process one flow data holding the evidence given, through a pipeline whose only element is the Cloud Request Engine, and give back the body of the data request.
◆ test_a_prefix_ranks_the_same_in_any_letter_case()
| tests.test_all_evidence_sent.TestAllEvidenceSent.test_a_prefix_ranks_the_same_in_any_letter_case | ( | self | ) |
Evidence keys ignore letter case, so Location ranks as location and SERVER as server.
◆ test_a_reserved_name_is_left_out_under_any_prefix_and_case()
| tests.test_all_evidence_sent.TestAllEvidenceSent.test_a_reserved_name_is_left_out_under_any_prefix_and_case | ( | self | ) |
The letter case of the key does not change which name the service reads, so a reserved name under any prefix is left out whatever its case.
◆ test_a_reserved_name_is_never_sent_from_evidence()
| tests.test_all_evidence_sent.TestAllEvidenceSent.test_a_reserved_name_is_never_sent_from_evidence | ( | self | ) |
The service reads its credentials and the property list from these names, so Evidence carrying one of them would sit beside the engine's own values with no way to know which one the service applied. The specification says Evidence under any prefix whose key strips to values, resource, license or licence, in any letter case, MUST be left out.
◆ test_each_prefix_wins_over_every_later_one()
| tests.test_all_evidence_sent.TestAllEvidenceSent.test_each_prefix_wins_over_every_later_one | ( | self | ) |
evidence.md lists query, header, cookie, server, fiftyone and location from highest to lowest precedence, and ranks any other prefix alphabetically after them. Each pair of prefixes gives one name, added higher first so the order added cannot decide it, and the higher prefix's value is the one sent.
◆ test_evidence_the_service_does_not_list_is_sent()
| tests.test_all_evidence_sent.TestAllEvidenceSent.test_evidence_the_service_does_not_list_is_sent | ( | self | ) |
The stand-in service lists none of these three names, so a store that keeps only the accepted Evidence loses all three before the engine reads them. The specification says the engine makes the request "with every Evidence value in the Flow Data, apart from the reserved names and the web request view".
◆ test_evidence_the_service_lists_is_still_sent()
| tests.test_all_evidence_sent.TestAllEvidenceSent.test_evidence_the_service_lists_is_still_sent | ( | self | ) |
An accepted key is still sent, so reading the set aside Evidence as well has not displaced the Evidence the engine sent before.
◆ test_one_name_in_two_letter_cases_is_sent_once()
| tests.test_all_evidence_sent.TestAllEvidenceSent.test_one_name_in_two_letter_cases_is_sent_once | ( | self | ) |
Evidence keys ignore letter case, so header.User-Agent and query.user-agent name the same value, and the query value wins under the precedence order. The name is sent once, spelled as the winning key spells it.
◆ test_other_prefixes_rank_by_the_prefix_alone()
| tests.test_all_evidence_sent.TestAllEvidenceSent.test_other_prefixes_rank_by_the_prefix_alone | ( | self | ) |
Other prefixes rank alphabetically by the prefix, so ab comes before ab-c, although the key ab-c.n sorts before ab.n because a hyphen sorts before a dot.
◆ test_query_evidence_wins_whether_listed_or_not()
| tests.test_all_evidence_sent.TestAllEvidenceSent.test_query_evidence_wins_whether_listed_or_not | ( | self | ) |
Query evidence takes precedence over header and cookie evidence of the same name, whether the service lists the name or not.
◆ test_the_name_sent_is_everything_after_the_first_dot()
| tests.test_all_evidence_sent.TestAllEvidenceSent.test_the_name_sent_is_everything_after_the_first_dot | ( | self | ) |
The prefix is the text before the first dot, and removing it leaves the rest of the key, dots included. So a.license is not the reserved name license, and a key with no dot is sent whole.
◆ test_the_name_sent_keeps_the_letter_case_given()
| tests.test_all_evidence_sent.TestAllEvidenceSent.test_the_name_sent_keeps_the_letter_case_given | ( | self | ) |
The name is sent in the letter case of the evidence key, as .NET sends it, rather than lower-cased.
◆ test_the_web_request_view_is_never_sent()
| tests.test_all_evidence_sent.TestAllEvidenceSent.test_the_web_request_view_is_never_sent | ( | self | ) |
A web integration adds the web request itself under server.http-request. It is a view of the whole request and not a value to send, so the specification says it MUST be left out.
