Commit Graph

381 Commits

Author SHA1 Message Date
Steve Powell f87babeb55 Complete parser rewrite and added some new tests. 2012-07-24 14:01:41 +01:00
Steve Powell 60032e3ba3 Removed CR as valid char in headers and command;
update tests to reject such frames
augment escapes to include \r as escape for CR
simplify grammar
2012-07-20 14:47:36 +01:00
Steve Powell f72d6606fa Add tests for trailing \r in COMMAND and header-value;
o serialize-header augmented to add extra \r to trailing \r
2012-07-19 16:50:46 +01:00
Steve Powell db8ccc279f Introduced parse_header_name with BACKSLASH escapes;
-- augmented unit test
  -- modified serialise_header/1 to escape key as well as value
2012-07-18 17:18:56 +01:00
Steve Powell d90db2ba9c Use content-length header MACRO in tests. 2012-07-18 12:20:25 +01:00
Steve Powell ece5363bb0 Tweak wait time in lifecycle tests for CI. 2012-07-17 11:55:29 +01:00
Steve Powell bb3370087e Improve diagnostics on destinations test failures. 2012-07-16 10:51:36 +01:00
Steve Powell 1d9bcf350b Simplify frame unit tests. 2012-07-11 11:55:29 +01:00
Steve Powell 9abd4ebb42 Refactor test function 2012-07-10 16:12:48 +01:00
Steve Powell 44053f3418 Merge in default 2012-07-10 12:15:34 +01:00
Steve Powell 2ef71b4e10 Accept CRLF as inter-frame NL; command terminator and header terminator. 2012-07-10 12:14:26 +01:00
Steve Powell 47024a5ed3 Made test in test more explicit. 2012-07-09 15:22:12 +01:00
Steve Powell 01e73d952c Increment default wait time for assertListenerAfter() used in lifecycle tests. 2012-07-06 14:55:38 +01:00
Steve Powell 2f2b39126c Reworked base.py listener to record message arrival number
and change test in destinations.py to expect two responses and check the order of arrival.
Rename test to test_durable_subscription.
2012-07-06 14:53:45 +01:00
Steve Powell 23d1f80dbb Instrumented base.py to get more info from errors on CI 2012-06-28 17:09:49 +01:00
Steve Powell ab2d44b2da Modified tests for interframe heartbeat, null bytes and carriage returns (sic) with test for intra-command carriage return. 2012-06-01 15:19:25 +01:00
Steve Powell f60ef40e47 Added tests for interframe heartbeat, null bytes and carriage returns (sic) with test for intra-command carriage return. 2012-06-01 15:13:21 +01:00
Simon MacMullen 2301d4fd17 Unbreak the tests. Ahem. 2012-05-29 14:31:00 +01:00
Steve Powell 14f41ed45e Destination on MESSAGE frames reflects SEND destination, not SUBSCRIBE destination;
Treat default exchange and amq.topic exchange specially;
Escape content;
Adjust tests to cope with new expectations.
2012-04-10 13:47:52 +01:00
Steve Powell 27ac436eb3 Update connect_options.py to check for error frame (if bad connect)
and to set default user before test (so it passes).
2012-03-26 10:53:34 +01:00
Simon MacMullen e34be08226 Test implicit connections even if we *are* doing SSL tests, by turning implicit connect on just for the test. 2012-03-15 18:00:31 +00:00
Steve Powell 1f6d097f43 Updated test ssl.config to remove default user (and implicit connect);
adjusted tests to avoid using implicit connect everywhere;
put check in login_header to return undefined if lookup returns undefined.
2012-03-15 11:37:02 +00:00
Simon MacMullen a40eed1dff Add failing test. We can't implement this in Python since stomp.py seems buggy in this area anyway (I'm not sure it sends DISCONNECT). 2012-03-12 17:49:05 +00:00
Steve Powell 657e1103c4 Allow "server:.*" header on CONNECTED frames in tests. 2012-02-24 15:44:55 +00:00
Simon MacMullen f08620d1eb Forgot to add this... 2012-02-20 17:07:16 +00:00
Simon MacMullen c5638606f7 "Promote" implicit_connect to the top level since it is no longer just for default_user 2012-02-20 16:44:57 +00:00
Simon MacMullen e31a0f7dee SSL client certificate authentication. In theory based on Shane Hathaway's patch but there's probably nothing left of it by now. 2012-02-20 16:07:18 +00:00
Emile Joubert db6410658f Merged bug24670 into default 2012-02-06 15:50:53 +00:00
Simon MacMullen f358bf688c Merge bug24606 2012-02-03 13:07:05 +00:00
Emile Joubert d4f7bec443 Update copyright 2012 2012-02-02 17:52:58 +00:00
Matthias Radestock d4dd7b7b96 refactor: use new rabbit_misc:format/2 2012-02-02 15:51:33 +00:00
Simon MacMullen ccfbf4c6e4 Fix the little test client so it actually uses the parser correctly and does not drop messages. 2012-01-30 16:33:38 +00:00
Simon MacMullen f3a4223ed8 Actually pay attention to the rabbit_stomp_frame:parse/2 API. 2012-01-30 14:55:00 +00:00
Simon MacMullen 9353dcbeaf Continue on our quest towards being able to count. 2012-01-18 15:42:16 +00:00
Simon MacMullen c832d157fd Mask lumpiness 2012-01-18 15:38:11 +00:00
Simon MacMullen df14cc2f21 Turns out I actually can't count. Previous version assumed one send stats for every recv stats, but the recv ones tend to run behind... 2012-01-18 15:29:11 +00:00
Simon MacMullen 4fe81c1ae6 A simple publish-and-consume-as-fast-as-you-can test since I'm not convinced about the performance of some of the clients we've poked at. I was going to call this multicast_plain but I think puns like that would be discouraged. 2012-01-18 12:08:14 +00:00
Steve Powell 4f304d6f8a Put description in test. 2011-11-29 10:23:17 +00:00
Steve Powell 8a252ff86e Simple test for rejection. 2011-11-25 13:15:51 +00:00
Emile Joubert b8dc126e16 Whitespace 2011-11-10 18:17:47 +00:00
Steve Powell 1be74eb32a Add test to demonstrate problem. 2011-11-10 10:03:11 +00:00
Steve Powell db0afba9da Merge in default 2011-08-26 13:46:25 +01:00
Rob Harrop 945666a34b Support header trimming for 1.0 clients 2011-08-25 12:41:26 +01:00
Steve Powell 4a950ab8f7 Prevent premature death of stomp_reader and stomp_processor to clean up connection:
-  change reader to temporary from intrinsic
-  protect alien calls from processor by catch so as to avoid premature death
-  call processor:flush_and_die/1 from reader when mainloop exits before reader dies
2011-08-24 14:50:48 +01:00
Steve Powell 1aadde8224 Merge in default. 2011-08-17 14:26:30 +01:00
Steve Powell ed027f0fb2 Improve ack tests 2011-08-17 14:20:57 +01:00
Marek Majkowski ce55129e4d Added one more test - no content length + binary (utf) data on the wire. 2011-08-11 12:21:01 +01:00
Steve Powell fb0fabd96c Add test to check we do NOT supply a content-type header when omitted 2011-08-10 09:18:25 +01:00
Steve Powell 1d81a8a0b2 Remove the default content-type header for SENT messages. 2011-08-09 17:20:56 +01:00
Steve Powell 8b4b030e90 Whoops -- adjust again. 2011-08-02 14:37:21 +01:00
Steve Powell d58c8ce4d5 Sleep slightly before closing socket to allow test_send_and_disconnect() to work. 2011-08-02 13:02:19 +01:00
Steve Powell f5981b0590 Tweak to test to diagnose CI build failures. 2011-08-02 12:30:10 +01:00
Steve Powell 5494947bd0 A tweak to test to diagnose CI failures. 2011-08-02 12:07:40 +01:00
Steve Powell 67b3d3e7c4 Upped wait times in three tests to see if CI builds are better. See bug24312. 2011-07-29 12:23:47 +01:00
Steve Powell ca1abbeb7d Adjust wait time again in test. 2011-07-27 17:21:01 +01:00
Steve Powell 3ac796e511 Recoded aessertTrue() in test_interleaved_receipt_no_receipt_tx. 2011-07-27 16:54:06 +01:00
Rob Harrop e9663d0651 Support for durable subscriptions 2011-07-20 18:20:14 +01:00
Rob Harrop cc5331c642 Merge with bug23864 2011-07-20 09:32:33 +01:00
Rob Harrop e6499f9cdc Support /temp-queue/ and /reply-queue/ destinations 2011-07-19 16:15:59 +01:00
Rob Harrop c7a1664bde Tests for /amq/queue destinations 2011-07-19 13:08:10 +01:00
Rob Harrop d65f567718 Parsing code for /amq/queue destinations 2011-07-19 11:19:56 +01:00
Steve Powell f858dff465 Moved connect tests to new script; implicit_connect not default; in tests only. 2011-06-29 16:59:34 +01:00
Rob Harrop 22736c8a5e Merge in default 2011-06-13 16:36:23 +01:00
Rob Harrop c7d7bd72be Fixed stupid commenting out of tests 2011-06-13 16:27:17 +01:00
Steve Powell 4ee8146e5f Merged in default and corrected ssl support clashes. 2011-06-08 17:44:43 +01:00
Steve Powell 8375e0af6b Add simple test description to reliability test 2011-06-08 11:42:08 +01:00
Steve Powell 7478ee6ce9 Merged in default 2011-06-08 11:05:29 +01:00
Rob Harrop 53b24f3d0e Merge with default 2011-06-07 14:47:54 +01:00
Steve Powell 4bcb7e7917 Merged bug24088 into default.
Also shortened python test descriptions to a single line.
2011-06-07 12:29:33 +01:00
Rob Harrop e13534c60b Tests for closing connection while sending. 2011-06-06 17:03:16 +01:00
Rob Harrop a6674fab55 Make sure all tests run again 2011-06-06 16:22:35 +01:00
Rob Harrop ed5e569c38 Tests for implicit connect 2011-06-06 11:49:10 +01:00
Rob Harrop c597720ea8 Support default_user connection 2011-06-06 11:03:17 +01:00
Rob Harrop 6d07bfa27c SSL tests running again 2011-06-03 14:47:36 +01:00
Rob Harrop 0c58cb8819 Removed pointless, erroneous test that was breaking CI 2011-06-03 11:34:52 +01:00
Rob Harrop 917ae42a82 Merge with default, but need to reinstate the SSL tests in the Makefile 2011-06-02 17:10:16 +01:00
Rob Harrop 2ae869dc60 Tweaked timeout on the receipt test to allow for slower machine. Removed stupid comment and added a better failure message 2011-06-02 16:16:16 +01:00
Steve Powell 0787042b45 Header 'heartbeat' renamed to 'heart-beat' throughout, as per Spec. 2011-05-19 15:43:40 +01:00
Simon MacMullen 2525e2667a Cope correctly with bad vhosts too. 2011-05-11 17:32:19 +01:00
Simon MacMullen c2c7ef6ce8 Add tests for bad username / password, and actually pass them... 2011-05-03 16:14:13 +01:00
Simon MacMullen a1a7ef95bd Merge from default 2011-04-11 17:29:32 +01:00
Rob Harrop 22c5d21ca3 Fixed bug with SSL socket setup. Added full SSL communication test 2011-03-03 15:22:55 +00:00
Rob Harrop 3fddfacbd2 SSL connections largely working. Rough connection test 2011-03-02 23:00:25 +00:00
Steve Powell ae45163bd9 Merged Bug23847 into default. 2011-03-01 11:35:57 +00:00
Steve Powell c66a276945 Added check for explicit receipt-id on DISCONNECT in test. 2011-03-01 11:32:22 +00:00
Steve Powell e3711110e2 Removed blank line in rabbit_stomp_processor.erl & merged Bug23718 into default. 2011-02-28 16:50:26 +00:00
Rob Harrop 4f9252b94c Fixed issue in adhoc_convert_headers when AMQP message contains no extra headers 2011-02-28 13:38:55 +00:00
Rob Harrop 88af91bc63 Fixed bug in receipt processing when interleaving receipt/no-receipt messages. Increased test coverage for receipts 2011-02-24 17:12:21 +00:00
Rob Harrop 96fd2d225e Merge with default 2011-02-24 15:44:36 +00:00
Rob Harrop 5884df1413 Reworked tests to check the actual receipts 2011-02-24 15:44:16 +00:00
Steve Powell 2b3c8c4716 Merged in default. 2011-02-24 15:27:18 +00:00
Steve Powell b93f85086e Tidied parsing.py again to <=80 byte lines. 2011-02-24 15:26:43 +00:00
Rob Harrop 9da9ae5da8 Removed trailing spaces and tweaked some indentation 2011-02-24 14:34:06 +00:00
Steve Powell caeddf92f9 Changed test to expect new message text. 2011-02-23 18:27:34 +00:00
Steve Powell acb7cca464 Shortened some new lines in parsing.py. 2011-02-23 17:47:13 +00:00
Steve Powell 306d04daae Fix MESSAGE send frame body fragment assembly. 2011-02-22 17:24:59 +00:00
David Wragg 86f2d19b93 Merge default into bug23568 2011-02-22 03:25:10 +00:00
Steve Powell f55f9a2aae Merged in default. 2011-02-21 17:02:22 +00:00
Steve Powell 6153828be2 Added test for packetizing on send;
added fix for packet end in escape sequence;
added get of trailing null with content length.
2011-02-21 17:01:24 +00:00
Steve Powell 7b8ae8f1cb Merged Bug23853 into default. 2011-02-21 12:06:49 +00:00
Steve Powell 30c1062622 Added content with nulls tests to erlang unittests. 2011-02-18 16:16:56 +00:00
Steve Powell e25e87f226 Further fixes to test in parsing.py 2011-02-17 18:33:08 +00:00
Steve Powell fbbadfb6b4 Fix minor error in test for embedded nulls 2011-02-17 17:25:40 +00:00
Steve Powell 8574dbc663 Added test for embedded nulls in STOMP MESSAGE body. 2011-02-17 16:48:41 +00:00
Steve Powell 95c8c95466 Merged bug23527 into default 2011-02-17 12:33:05 +00:00
Rob Harrop 7aa525dd1d Add support for persistent header 2011-02-17 10:29:16 +00:00
Rob Harrop 97262e429f DISCONNECT now triggers connection and channel shutdown. Receipts for DISCONNECT are sent after this has happenend 2011-02-16 15:06:46 +00:00
Rob Harrop 5872bd908c Rough work on DISCONNECT fixes 2011-02-16 12:10:09 +00:00
Rob Harrop 506fc367cf Fixed issue with multi-confirm and added support for TX receipts 2011-02-16 11:54:13 +00:00
Rob Harrop d764c839bd Working confirm-triggered receipts for non-transactional SEND 2011-02-16 09:56:39 +00:00
David Wragg 89824d3c16 Merge default into bug23568 2011-02-15 15:51:47 +00:00
Steve Powell b53a83188a Merged in bug23527 2011-02-11 12:27:12 +00:00
Rob Harrop f2fcf05ed4 Removed race in the tests 2011-02-09 17:10:19 +00:00
Rob Harrop 69898554a7 Merge default 2011-02-09 16:59:12 +00:00
David Wragg ecd2f8fe42 Hook into the new rabbitmq-public-umbrella testing support 2011-02-01 16:03:11 +00:00
Rob Harrop 25f0279997 Reworked TCP send to use rabbit_net:port_command 2011-01-26 17:46:27 +00:00
Rob Harrop 23876fcd15 Reworked header conversion - slightly faster and quite a bit nicer 2011-01-26 14:48:02 +00:00
Rob Harrop c7dba8206c Changed how bytes are read from the socket - better performance for large messages 2011-01-25 15:21:35 +00:00
Rob Harrop 29699ea26a Merge with default 2011-01-24 23:50:22 +00:00
Rob Harrop 73350fe6af Reworked parser to use binaries 2011-01-19 20:50:10 +00:00
Rob Harrop 72d6bd51b0 Reworked body content parsing 2011-01-19 15:53:20 +00:00
Steve Powell 814f316b37 Put short delay into destinations test 2011-01-19 11:24:57 +00:00
Steve Powell 8a3694859b UN/SUBSCRIBE error messages contain the subscription as passed in by the user. 2011-01-18 16:24:42 +00:00
Steve Powell cb15502118 Merged default (with 1.1 support) and got tests working again. 2011-01-18 15:23:07 +00:00
Rob Harrop ba4d368f4a Fixed up bugs in new parser 2011-01-18 14:53:54 +00:00
Steve Powell 55f2e7eb95 Added receipted unsubscribe tests and check for send after unsubscribe properly. 2011-01-18 12:46:28 +00:00
Rob Harrop e83b25e547 Merge with bug23447 2011-01-18 11:54:09 +00:00
Rob Harrop e8c86bd131 Merge with default 2011-01-18 11:03:35 +00:00
Steve Powell 6f8e904f9b Merge in bug23601 fixes 2011-01-17 18:04:21 +00:00
Steve Powell e09807c6c4 Refactored lifecyclke tests 2011-01-17 17:55:27 +00:00
Rob Harrop ebb918804a Added support for multi NACK 2011-01-17 12:35:45 +00:00
Rob Harrop 35a9f337f2 Merge bug23685 into default 2011-01-17 11:18:29 +00:00
Steve Powell 8c5759a3d4 Added receipted unsubscribes to lifecycle test
Augnmented handle_info to allow basic.cancel_ok records;
tweaked base.py Latch class not to underflow count;
receipted tests in lifecycle check for receipts.
2011-01-14 17:09:50 +00:00
Rob Harrop 939a6a77c2 Tests and improvements for header value stripping, escaping and duplication 2011-01-14 15:39:58 +00:00
Rob Harrop 014d7ec03a Exploratory rework of frame parser 2011-01-14 12:46:58 +00:00
Steve Powell fa5f530a18 Added tests to check queue subscriptipn UNSUBSCRIBE
Augmented listener class (python) to allow debugging;
patch Latch, natch.
2011-01-14 10:49:38 +00:00
Rob Harrop 65221a020b Reworked handling of AMQP errors so that the STOMP session is terminated too 2011-01-13 15:38:12 +00:00
Steve Powell b2f87b62c9 Added tests for unsubscribe from queue by destination and id 2011-01-13 15:24:25 +00:00
Steve Powell 2e5d05e692 Missing subscription tag does not terminate channel process.
error frame delivered instead of message frame;
test (lifecycle.py) updated to check for no errors at crucial points.
2011-01-13 14:18:25 +00:00
Rob Harrop 162fd62b6d Added support for NACK 2011-01-11 13:57:59 +00:00
Rob Harrop 2a9487d4fa Removed stray debug line 2011-01-10 20:27:57 +00:00
Rob Harrop 48b77578a9 Fixed issue with merge that broke version negotiation tests 2011-01-10 20:27:32 +00:00
Rob Harrop 9fbb78c2b4 Fixed issue with arbitrary headers not being included in MESSAGE frames 2010-11-17 09:09:45 +00:00
Rob Harrop a01a6d5290 Fixed missing version header in CONNECTED frames 2010-11-12 07:23:02 +00:00
Rob Harrop e4b3035bf8 Basic heartbeating for both server and client 2010-11-09 19:10:56 +00:00
Rob Harrop 888214a640 tweaked test case to better exercise negotiation 2010-11-09 14:39:50 +00:00
Rob Harrop 3078d153da test for prefetch with topics 2010-11-09 14:30:56 +00:00
Rob Harrop 7f4cf91813 Reworked ack handling to be inline with the 1.1 spec. Re-introduced the prefetch-count header to make ACK more useful 2010-11-09 14:12:59 +00:00
Rob Harrop 043a1de112 Version negotiation 2010-11-09 12:45:00 +00:00
Rob Harrop ada5a8e81d Partially complete version negotiation 2010-11-09 11:57:20 +00:00
Rob Harrop fdfbf9a516 Utility for calculating the maximum version shared by the client and the server 2010-11-09 11:17:01 +00:00
Rob Harrop 101e46c9ea Moved STOMP Headers -> AMQP Properties into util 2010-10-28 12:57:58 +01:00
Rob Harrop 2198bf21d1 Moved the AMQP Properties -> STOMP headers conversion over to util 2010-10-28 12:04:40 +01:00
Rob Harrop b2b531e98e Decided to move consumer tag processing in the end 2010-10-28 09:17:38 +01:00
Rob Harrop f39b804f27 Tests for longstr_field. Moved ack_mode calculation to util and added unit tests 2010-10-28 08:59:43 +01:00
Michael Bridgen 9d8ac7114b Account for /exchange//something, which would previously have referred to exchange something
with no routing key (due to the removal of all leading blanks. We choose to interpret it as
referring to the default exchange, and reject it on the basis that you cannot bind to the
default exchange so it cannot follow our /exchange semantics.
2010-10-18 17:16:33 +01:00
Rob Harrop 9d899c323b support for escaping / in destination names 2010-10-18 13:29:51 +01:00
Rob Harrop 389cdb24a9 made the tests a bit smarter when waiting for multiple messages 2010-10-12 13:02:23 +01:00
Rob Harrop 4894ed304f segmented /queue from other destinations on a separate channel 2010-10-07 17:31:18 +01:00
Rob Harrop b927af39f4 added some more error case tests 2010-10-07 11:15:17 +01:00
Rob Harrop 8515309093 changed how we reference stomppy now, so that it is pulled down from hg 2010-10-07 11:09:50 +01:00
Rob Harrop b3b5502ab1 adding missing test file, correct branch this time 2010-10-07 10:32:36 +01:00
Rob Harrop 5319764146 reworked error handling to get better messages when dealing with invalid destinations 2010-10-07 09:49:47 +01:00
Rob Harrop a3f2bf17dc cosmetics 2010-10-06 15:25:55 +01:00
Rob Harrop 17307323ea more tests, and added /topic 2010-10-06 14:05:02 +01:00
Rob Harrop 1811e77e81 added all tests back in. removed stray io:format 2010-10-06 13:17:00 +01:00
Rob Harrop f8acc6b87d more tests for /queue. added a basic.qos call temporarily while I decide what to do with prefetch for /queue 2010-10-06 13:14:54 +01:00
Rob Harrop 3f9a113873 reworked tests and introduced /exchange and /queue destinations 2010-10-06 12:16:40 +01:00
Rob Harrop f7d4308997 Introduced /exchange support 2010-10-05 13:36:12 +01:00
Rob Harrop 68372b7e39 more unit tests for the destination parser 2010-10-01 14:49:23 +01:00
Rob Harrop 1d25309ded unit tests for the destination parser 2010-10-01 13:41:04 +01:00
Rob Harrop cfd1efb994 working on unit tests 2010-10-01 12:27:10 +01:00
Rob Harrop 3f7d45fa77 tests tweaked to accound for different error frames 2010-09-30 12:54:46 +01:00
Marek Majkowski 2c519a54df Merging default into bug21318. 2009-08-27 11:46:27 +01:00
Marek Majkowski 132ee7d62e Make stomp plugin working again, after SSL changes to server code 2009-08-27 11:43:49 +01:00
Marek Majkowski 06b4ffd746 Test script is now executed as os:cmd. God elp us with escaping. 2009-08-25 15:24:15 +01:00
Marek Majkowski 6cb8c3b72f Added test for bug 20390. 2009-08-25 13:11:45 +01:00
Marek Majkowski b8a1052115 removed static netcat files, right now the tests are in python 2009-08-14 16:16:44 +01:00
Marek Majkowski c12fb1e0ca Added simple test suite as a python script. make test now returns 70% of stomp code coverage. 2009-07-24 17:32:02 +01:00
Tony Garnock-Jones 51693e51f5 Examples of newlines in nonstandard places 2009-07-17 11:53:18 +01:00
Tony Garnock-Jones ad0c323e57 Test scripts I used to track down the recent issues 2009-02-19 13:02:27 +00:00