Wire Sysio Wire Sysion 1.0.0
Loading...
Searching...
No Matches
catch_version.cpp
Go to the documentation of this file.
1/*
2 * Created by Phil on 14/11/2012.
3 * Copyright 2012 Two Blue Cubes Ltd. All rights reserved.
4 *
5 * Distributed under the Boost Software License, Version 1.0. (See accompanying
6 * file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
7 */
8
9#include "catch_version.h"
10#include <ostream>
11
12namespace Catch {
13
15 ( unsigned int _majorVersion,
16 unsigned int _minorVersion,
17 unsigned int _patchNumber,
18 char const * const _branchName,
19 unsigned int _buildNumber )
20 : majorVersion( _majorVersion ),
21 minorVersion( _minorVersion ),
22 patchNumber( _patchNumber ),
23 branchName( _branchName ),
24 buildNumber( _buildNumber )
25 {}
26
27 std::ostream& operator << ( std::ostream& os, Version const& version ) {
28 os << version.majorVersion << '.'
29 << version.minorVersion << '.'
30 << version.patchNumber;
31 // branchName is never null -> 0th char is \0 if it is empty
32 if (version.branchName[0]) {
33 os << '-' << version.branchName
34 << '.' << version.buildNumber;
35 }
36 return os;
37 }
38
40 static Version version( 2, 7, 2, "", 0 );
41 return version;
42 }
43
44}
os_t os
Version const & libraryVersion()
auto operator<<(std::ostream &os, LazyExpression const &lazyExpr) -> std::ostream &
Version(Version const &)=delete