You've already forked libopenshot
mirror of
https://github.com/OpenShot/libopenshot.git
synced 2026-03-02 08:53:52 -08:00
Tests: test << for Coordinate, Fraction, Point
This commit is contained in:
@@ -32,6 +32,10 @@
|
||||
|
||||
#include "Fraction.h"
|
||||
|
||||
#include <map>
|
||||
#include <vector>
|
||||
#include <sstream>
|
||||
|
||||
using namespace std;
|
||||
using namespace openshot;
|
||||
|
||||
@@ -148,3 +152,12 @@ TEST_CASE( "Reciprocal", "[libopenshot][fraction]" )
|
||||
CHECK(f1.ToFloat() == Approx(1.77777f).margin(0.00001));
|
||||
CHECK(f1.ToDouble() == Approx(1.77777f).margin(0.00001));
|
||||
}
|
||||
|
||||
TEST_CASE( "Operator ostream", "[libopenshot][fraction]" )
|
||||
{
|
||||
std::stringstream output;
|
||||
openshot::Fraction f3(30000, 1001);
|
||||
|
||||
output << f3;
|
||||
CHECK(output.str() == "Fraction(30000, 1001)");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user