Luca Boccassi
19da7a4cf6
Merge pull request #205 from sigiesec/split-testcases
...
Improved tests and implementation of message_t
2018-04-16 14:52:51 +01:00
Luca Boccassi
a186ed6ada
Merge pull request #203 from kurdybacha/master
...
Problem: message_t could be easier to construct and is missing equal not equal operators
2018-04-14 15:54:56 +01:00
Pawel Kurdybacha
f518a648ef
Problem: extended initializer lists only available in C++11
2018-04-14 14:06:32 +01:00
Pawel Kurdybacha
6caa5d19d3
Problem: message_t should be easier to construct
...
* Added overload constructor (c++11 only) taking iteratable object.
It would be easier to use std::string, std::array etc to construct
a message now. Making it a draft for now in case it is too greedy
and needs to be more specialize.
* Added equal and not euqal operator to message_t as a recommended
and expected way of comparing objects in C++.
* deprecated C style equal method as operator== should be used instead
(point above).
* Added message_t test covering all available message_t's constructors
2018-04-14 12:13:44 +01:00
Luca Boccassi
3185dd1051
Merge pull request #202 from kurdybacha/master
...
Problem: non consistent whitespace formatting
2018-04-13 17:58:43 +01:00
Pawel Kurdybacha
40c55018b2
Problem: create_destroy test not assigned properly
2018-04-13 17:38:51 +01:00
Pawel Kurdybacha
8353e8460f
Problem: non consistent whitespace formatting
...
* Converted tabs to to 4 spaces to be consistend with the rest of the
code
* Stripped white spaces from the end of lines
2018-04-13 17:35:41 +01:00
Simon Giesecke
2aac1dffa3
Problem: bad code style in operator==
...
Solution: simplified code
2018-04-13 11:38:16 -04:00
Simon Giesecke
4d0418750e
Problem: no tests for move-assignment
...
Solution: added test cases
2018-04-13 11:35:00 -04:00
Simon Giesecke
c92afb675e
Problem: message_t::operator== is absurdly inefficient and constructs temporary copies of both operands
...
Solution: implement operator== using memcmp instead
2018-04-13 11:28:40 -04:00
Simon Giesecke
438bad28e6
Problem: insufficient test cases for operator==
...
Solution: added test cases
2018-04-13 11:24:36 -04:00
Simon Giesecke
4367bd6128
Problem: code duplication in equals/operator==
...
Solution: implemented equals using operator==
2018-04-13 11:21:05 -04:00
Simon Giesecke
799c89cb09
Problem: several test cases mixed in message.constructors
...
Solution: split up into test cases for various ctors and equality operators
2018-04-13 11:20:07 -04:00
Luca Boccassi
25196e5bb8
Merge pull request #201 from sigiesec/add-poller-tests
...
Problem: insufficient tests for poller_t, bad usability since caller of add must store function object
2018-04-13 15:43:20 +01:00
Simon Giesecke
5b1ab44264
Problem: insufficient tests for poller_t, bad usability since caller of add must store function object
...
Solution: added tests, added size() method, added add deprecated overload with former signature, changed new add signature to accept handler by value
2018-04-13 16:24:46 +02:00
Pawel Kurdybacha
1975818171
Problem: poller's handler not aware of event type. ( #200 )
...
* Problem: Poller's handler not aware of event type.
It was possible to register a handler for more than one event types but
impossible to distinguish which event is being handled.
Now events are passed to a handler.
Besides that some other changes:
* new test covering changes in the poller
* modified existing tests to cover changes in the poller
* defined handler_t in poller_t scope for more convinient use
and simpler code
* helper loopback binder to be re-used in tests
* Problem: CMake build fails on Windows
Issue #199
It seems that with GCC on Linux <array> is implicitly included
by one of stl includes already in zmq.hpp but it breaks on Windows
with Visual Studio.
Adding explicit include for array.
Can not verify right now but this change is a good practice
so creating a pull request.
* Poller: array include not between C++11 guards
2018-04-09 08:22:31 +01:00
Luca Boccassi
65475cb603
Merge pull request #198 from michael-hart/master
...
Added include directory to CMake instructions
2018-04-08 13:06:59 +01:00
Michael Hart
9c7b9e88af
Added include directory to CMake instructions
2018-04-08 11:58:55 +01:00
Luca Boccassi
bf39928c93
Merge pull request #196 from kurdybacha/master
...
Problem: poller_t does not have great test coverage
2018-04-08 00:51:44 +01:00
Pawel Kurdybacha
18f8035ba8
Problem: poller_t does not have great test coverage
...
@sigiesec's recent commits with gtests and basics tests for zmq
types (thanks for that!) makes it too convinient to not add some more tests.
* Adding some simple tests for poller_t
* Stripped whitespaces from poller implementation.
2018-04-07 23:00:10 +01:00
Luca Boccassi
9c1b785edb
Merge pull request #195 from kurdybacha/master
...
Problem: Draft build not enabled for git cloned cppzmq.
2018-04-07 15:30:11 +01:00
Pawel Kurdybacha
34e5b98917
Problem: Draft build not enabled for git cloned cppzmq.
...
When cppzmq is build out of source e.g. ${CMAKE_SOURCE_DIR}/build:
mkdir build
cd build
cmake ..
then .git is not found properly, DRAFT build not enabled and poller test
not added to pool of tests.
2018-04-07 15:08:24 +01:00
Luca Boccassi
5ebc7fe32f
Merge pull request #194 from sigiesec/add-initial-tests
...
Add some initial tests, add some build/version CI variants
2018-04-03 17:51:54 +01:00
Simon Giesecke
cc5f4050dc
Problem: no build/tests with DRAFT
...
Solution: added initial test case
2018-04-03 18:41:44 +02:00
Simon Giesecke
68cbb9e57c
Problem: snowballing
...
Solution: stop bash on first error
2018-04-03 18:41:44 +02:00
Simon Giesecke
83f854869a
Problem: no tests for socket_t ctor accepting enum socket_type
...
Solution: added test case
2018-04-03 18:41:44 +02:00
Simon Giesecke
1616c0fad2
Problem: test file not correctly named
...
Solution: move and split example_add.cpp
2018-04-03 18:41:44 +02:00
Simon Giesecke
80dc604ed0
Problem: No tests for libzmq 4.2.0
...
Solution: add travis job with libzmq 4.2.0
2018-04-03 18:41:44 +02:00
Simon Giesecke
63f81e40d6
Problem: code coverage not working
...
Solution: build tests within cppzmq build, and add separate demo
2018-04-03 18:41:32 +02:00
Simon Giesecke
b737b9f1de
Problem: no test cases
...
Solution: added a few initial test cases
2018-04-02 14:13:05 +02:00
Luca Boccassi
7db13d356a
Merge pull request #192 from sigiesec/add-travis-ci
...
Add basic test infrastructure
2018-03-29 17:59:48 +01:00
Simon Giesecke
07b583a99a
Problem: test not using cppzmq
...
Solution: add dependency on cppzmq
2018-03-29 18:46:04 +02:00
Giesecke
e5ca9a0a95
Problem: coverage is not enabled
...
Solution: add coveralls
2018-03-29 18:11:28 +02:00
Simon Giesecke
968473cdba
Problem: no test infrastructure
...
Solution: integrate googletest, with non-cppzmq test case for a start
2018-03-29 18:11:28 +02:00
Luca Boccassi
3937983afd
Merge pull request #191 from sigiesec/add-travis-ci
...
Add basic Travis CI for cppzmq
2018-03-28 12:10:49 +01:00
Simon Giesecke
7a8cc9d7cf
Problem: version detection broken, confuses libzmq and cppzmq versions
...
Solution: Fix version detection and cmake syntax errors
Fixes #182
2018-03-28 12:58:12 +02:00
Simon Giesecke
702d2fcf53
Problem: no CI for cppzmq
...
Solution: add travis-ci
2018-03-28 12:54:07 +02:00
Luca Boccassi
52c606ed86
Merge pull request #190 from sigiesec/fix-poller-api-error-handling
...
Fix copy/move constructors of poller_t, and make error handling consistent with rest of API
2018-03-26 16:21:42 +01:00
sigiesec
608613217e
Problem: inconsistent error handling in poller_t
...
Solution: make poller_t::add and poller_t::remove throw error_t on error, return void
2018-03-26 16:59:47 +02:00
sigiesec
16a76513e3
Problem: poller_t is copyable, but does not implement copying properly
...
Solution: make poller_t non-copyable, but properly movable
2018-03-26 16:58:13 +02:00
Luca Boccassi
84ab7a0fc6
Merge pull request #187 from cowo78/master
...
std::string conversion for zmq::message_t
2018-03-07 13:25:59 +00:00
Giuseppe Corbelli
0d1c20e2ea
Consistently indented some preprocessor directives.
...
Added a str() method and companion operator<<(std::ostream) similar to multipart_t.
Added some comments to mark the end of preprocessor instructions / class def / namespace def.
2018-03-07 14:14:09 +01:00
Giuseppe Corbelli
f945a7d032
Added an operator<<(std::ostream) to easily print out multipart_t contents using already defined str() method.
...
Added some comments to mark the end of preprocessor instructions / class def / namespace def
2018-03-07 14:11:41 +01:00
Luca Boccassi
a96e0ded64
Merge pull request #181 from WRidder/master
...
Added wrapper for context options
2018-01-28 10:58:18 +00:00
Wilbert van de Ridder
59f7d1ca2f
Added wrapper for context options
2018-01-27 19:14:35 +01:00
Luca Boccassi
25dbe96b86
Merge pull request #179 from jianhuachentw/master
...
fix installation source path of FindZeroMQ.cmake
2018-01-16 09:19:28 +00:00
Jian-Hua Chen
4367591ad6
fix installation source path of FindZeroMQ.cmake
...
when cppzmq is not the root folder of cmake (i.e., it is embedded in a
super project), CMAKE_SOURCE_DIR will not be the correct path to copy
FindZeroMQ.cmake.
2018-01-16 16:13:02 +08:00
Luca Boccassi
e2f91c06f6
Merge pull request #178 from minrk/rm-duplicate-find
...
fix updated FindZeroMQ
2018-01-15 19:24:23 +00:00
Min RK
8b92cb82aa
fix updated FindZeroMQ
...
- remove duplicate top-level install
- copy fallback code to cppzmqConfig.cmake.in
2018-01-15 10:43:00 -08:00
Constantin Rack
6aa3ab686e
Merge pull request #174 from minrk/findzeromq
...
call pkg-config fallback FindZeroMQ.cmake
2018-01-14 05:41:41 +01:00