mirror of
https://github.com/boostorg/build.git
synced 2026-02-14 12:42:11 +00:00
https://svn.boost.org/svn/boost/trunk ........ r51013 | jhunold | 2009-02-04 20:14:01 +0100 (Wed, 04 Feb 2009) | 3 lines Apply patch from Alexey Pakhunov for improved msvc assembler support. Fixes https://zigzag.lvk.cs.msu.su:7813/boost.build/ticket/214 ........ r51230 | jhunold | 2009-02-12 21:38:33 +0100 (Thu, 12 Feb 2009) | 7 lines Major refactoring of Qt4 toolchain featuring: - support for multiple 'using qt' statements. - auto-detection of Qt version using qmake. - support for user-specified version. - better debug messages. - support for toolset requirements. ........ r51275 | jhunold | 2009-02-16 20:35:15 +0100 (Mon, 16 Feb 2009) | 2 lines Fix: Correct handling of include paths with spaces. ........ r51300 | jhunold | 2009-02-17 20:30:19 +0100 (Tue, 17 Feb 2009) | 2 lines Add support for QtScriptTools (Qt-4.5) ........ r51313 | jhunold | 2009-02-18 20:11:49 +0100 (Wed, 18 Feb 2009) | 2 lines Refactoring: Rename uic-h to uic to get uniform toolnames. ........ [SVN r51334]
34 lines
791 B
C++
34 lines
791 B
C++
// (c) Copyright Juergen Hunold 2008
|
|
// Use, modification and distribution is subject to the Boost Software
|
|
// License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at
|
|
// http://www.boost.org/LICENSE_1_0.txt)
|
|
|
|
#define BOOST_TEST_MODULE QtScript
|
|
|
|
#include <QScriptEngine>
|
|
|
|
#include <boost/test/unit_test.hpp>
|
|
|
|
#include <iostream>
|
|
|
|
std::ostream&
|
|
operator << (std::ostream& stream, QString const& string)
|
|
{
|
|
stream << qPrintable(string);
|
|
return stream;
|
|
}
|
|
|
|
BOOST_AUTO_TEST_CASE( defines)
|
|
{
|
|
BOOST_CHECK_EQUAL(BOOST_IS_DEFINED(QT_SCRIPT_LIB), true);
|
|
}
|
|
|
|
BOOST_AUTO_TEST_CASE( script )
|
|
{
|
|
QScriptEngine myEngine;
|
|
QScriptValue three = myEngine.evaluate("1 + 2");
|
|
|
|
BOOST_CHECK_EQUAL(three.toNumber(), 3);
|
|
BOOST_CHECK_EQUAL(three.toString(), QLatin1String("3"));
|
|
}
|