blob: eb3cdfc29bbb89589faaadfcf6b7ea1e7390bc3b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
#include "rxcpp/rx.hpp"
#include "rxcpp/rx-test.hpp"
#include "catch.hpp"
SCENARIO("take_last sample"){
printf("//! [take_last sample]\n");
auto values = rxcpp::observable<>::range(1, 7).take_last(3);
values.
subscribe(
[](int v){printf("OnNext: %d\n", v);},
[](){printf("OnCompleted\n");});
printf("//! [take_last sample]\n");
}
|