Commit Graph

61 Commits

Author SHA1 Message Date
Lucie Gérard 9c5fc88388 Correct license for test files
According to QUIP-18 [1], all test files should be
LicenseRef-Qt-Commercial OR GPL-3.0-only

[1]: https://contribute.qt-project.org/quips/18

Pick-to: 6.7
Task-number: QTBUG-121787
Change-Id: I26d72e8de04d4c7c57b3b7838af5d033265de5ba
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Kai Köhne <kai.koehne@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2024-02-27 10:32:21 +01:00
Ulf Hermann d3c0515951 Remove remaining foreach in qml tests
Task-number: QTBUG-115808
Change-Id: If02f3cbb97e8a6035544d10ee2c23f5c87ed618c
Reviewed-by: Sami Shalayel <sami.shalayel@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2023-08-22 20:11:34 +02:00
Marc Mutz 8edbcdbeb4 Mark the module as free of Q_FOREACH, except where it isn't
The density of Q_FOREACH uses is high here, too high for this author,
unfamiliar with this code, to tackle in a short amount of time. But
they're concentrated in just a few TUs, so pick a different strategy:

Mark the whole module with QT_NO_FOREACH, to prevent new uses from
creeping in, and whitelist the affected TUs by #undef'ing
QT_NO_FOREACH locally, at the top of each file. For TUs that are part
of a larger executable, this requires these files to be compiled
separately, so add them to NO_PCH_SOURCES (which implies
NO_UNITY_BUILD_SOURCES, too). Created QTBUG-115808 to keep track of
this.

Task-number: QTBUG-115808
Change-Id: I29c377f939e3d747e3ce72c224c4ee722df7a95d
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2023-08-17 18:04:35 +02:00
Amanda Hamblin-Trué 1284917e72 tst_qqmlmoduleplugin: Clean up memory management
Task-number: QTBUG-115222
Change-Id: Ie0faf6d29e9d76abe72c9d7a0600b25a7fd47d14
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2023-08-15 10:31:18 +02:00
Marc Mutz 958cd3ee10 Port from container::count() and length() to size()
This is a semantic patch using ClangTidyTransformator as in
qtbase/df9d882d41b741fef7c5beeddb0abe9d904443d8:

  auto QtContainerClass = anyOf(
      expr(hasType(cxxRecordDecl(isSameOrDerivedFrom(hasAnyName(classes))))).bind(o),
      expr(hasType(namedDecl(hasAnyName(<classes>)))).bind(o));
  makeRule(cxxMemberCallExpr(on(QtContainerClass),
                             callee(cxxMethodDecl(hasAnyName({"count", "length"),
                                                  parameterCountIs(0))))),
           changeTo(cat(access(o, cat("size"), "()"))),
           cat("use 'size()' instead of 'count()/length()'"))

a.k.a qt-port-to-std-compatible-api with config Scope: 'Container',
with the extended set of container classes recognized.

Change-Id: Idb1f75dfe2323bd1d9e8b4d58d54f1b4b80c7ed7
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2022-10-07 23:38:48 +02:00
Lucie Gérard 0dc4fd240a Use SPDX license identifiers
Replace the current license disclaimer in files by
a SPDX-License-Identifier.
Files that have to be modified by hand are modified.
License files are organized under LICENSES directory.

Pick-to: 6.4
Task-number: QTBUG-67283
Change-Id: I63563bbeb6f60f89d2c99660400dca7fab78a294
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
2022-06-11 08:05:15 +02:00
Ulf Hermann cde9071322 Adapt qqmlmoduleplugin test to new metadata format
Fixes: QTBUG-97605
Change-Id: I73263048001f99a91e6d634dae1003ea17c86758
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-10-19 13:41:59 +02:00
Allan Sandfeld Jensen 72c3befaa2 Replace 0 pointer constants with nullptr
Replaced in most common patterns.

Change-Id: Idcaff1f2e915f29922702d3600a2e5f1e2418a7a
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-10-18 12:39:28 +02:00
Mitch Curtis e310dadef7 Consolidate test helpers into private libraries
Previously each test would include and build sources from the shared
folder. Now we make those sources a library, build it once, then have
each test link to it instead.

We also take the opportunity to move some helpers that qtquickcontrols2
had added into the quicktestutils library where it makes sense, and
for the helpers that don't make sense to be there, move them into
quickcontrolstestutils.

We add the libraries to src/ so that they are internal modules built as
part of Qt, rather than tests. That way we can use them in a standalone
test outside of qtdeclarative.

Task-number: QTBUG-95621
Pick-to: 6.2
Change-Id: I0a2ab3976fdbff2e4414df7bdc0808f16453b80a
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-09-13 21:17:04 +02:00
Ulf Hermann 79d0517a12 CMake: Always add the qmldir to the resource file system
We want to be able to load modules directly from the resource file
system, no matter if we build statically or dynamically. It's limited by
the need to load plugins, of course, but as most plugins are optional an
application can easily go this way and never include any plain QML files
in an application bundle.

Pick-to: 6.2
Change-Id: I94657a43b47e442722a83e1fb306680aa50b1bc3
Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
2021-07-01 13:25:56 +02:00
Ulf Hermann bae18ecd34 QtQml: Key plugins by URI where possible
This allows us to associate different qmldir files for the same module
with one another. Typically there is one qmldir file in the resource
file system and one in the QML import path. We cannot load plugins for
the latter, but usually we have already loaded any plugins we need. Now
we can detect this.

This requires us to construct a proper URI for implicit imports. The
easiest way to do this is to just use the URI from the qmldir if
available.

Modules with versions encoded in their paths and modules with multiple
plugins cannot be resolved by URI only. These continue to be keyed by
path. However, as we do not generate such modules, we will not
automatically get two instances of those, and we won't have to fall back
from one to the other.

Pick-to: 6.2
Change-Id: Ic79add936d263a8e559fd998fca15a6ae160952e
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-06-30 10:08:03 +02:00
Ulf Hermann a5404b2cb6 Deprecate QQmlExtensionPlugin::baseUrl()
The function does not play well with optional plugins as we don't need
to load those from any specific location. You also don't need this
function. There is exactly one place in qtdeclarative where it is used
and there it just provides a poor replacement for qmldir entries.

[ChangeLog][QtQml][Important Behavior Changes] The internal function
QQmlExtensionPlugin::baseUrl() has been deprecated. You don't need it
if you properly specify your module in the qmldir file.

Change-Id: I131c45e069e9c10744a0ad6126604a2600a6d93d
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2021-06-24 18:41:25 +02:00
Andreas Buhr 7e029878c0 Fix some "can be marked override" warnings
Change-Id: I13da0d085901314950c4fa0afb5853e183652e67
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
2021-02-23 16:50:07 +01:00
Fawzi Mohamed 212c5212c6 Fix tst_qqmlmoduleplugin on mac
* warn and assume case unsensitivity if pathconf fails (on FAT32 for
  example)
* adjust library name for debug compilation

Change-Id: I2ec45d5da35974b61c6e316738a59f2962532aed
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2020-08-11 10:58:28 +02:00
Laszlo Agocs b32a2151af Fix string-bytearray mistake in tst_qqmlmoduleplugin
Was causing an error with the latest qtbase. Switch to
QByteArrayLiteral.

Change-Id: I2370ccca5ac245a7d6678cc6888217d4757f562d
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2020-06-29 10:17:27 +02:00
Ulf Hermann 9d40cc4b63 Drop the "plugin cannot be loaded" extension to error messages
This message adds very little extra value, and it complicates the tests
that check for specific errors.

Change-Id: I58553a8cbc56c3333c8e9815518cca5fa01fdde1
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2020-06-17 17:09:33 +02:00
Ulf Hermann 5dc14c88f9 Allow QML plugins to be optional
If a plugin does nothing but load the library that provides the types,
we can skip the plugin loading by linking the library directly. State
that in the qmldir file, and evaluate it when loading the module.

Task-number: QTBUG-84639
Change-Id: I2097237866a50f66c55e4653ad119fe10e18a893
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
2020-06-09 08:01:02 +02:00
Qt Forward Merge Bot 1b71204d81 Merge remote-tracking branch 'origin/5.15' into dev
Change-Id: I68014bc552793b6dea930744325876a8863aaef3
2019-10-09 01:01:34 +02:00
Ulf Hermann 914e030079 Use qmlProtectModule to protect a module from further modification
We don't need two mechanisms to do essentially the same thing.

QQmlTypeLoader::Blob::addImport() had an "optimization" to never check
for qmldir files of locked imports. This meant the first time you
imported a module with a plugin that locked the module you could use the
qmldir file to load additional .qml files afterwards. The second time
you imported the same thing, you couldn't. As this is not a great
example of consistent behavior, we drop this optimization and always
allow the qmldir files of plugins that lock the module to specify
additional QML files.

As a side effect of this, additional plugins listed in a qmldir file can
also now be loaded after the module has been locked by some other means.
However, any qmlRegisterFooBar() called from the module will be
prevented.

Change-Id: Idabb2bd5f75fc85b62f42625173672b4ae84382e
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-10-08 12:49:05 +02:00
Liang Qi 7e17fb2ded Merge remote-tracking branch 'origin/5.15' into dev
Conflicts:
	tests/auto/qml/qqmltypeloader/tst_qqmltypeloader.cpp

Change-Id: Id2e81000bcbd4de18fe22b085fdf5eed42c02516
2019-10-07 13:10:18 +02:00
Fabian Kosmale a3ccbde329 tst_qqmlmoduleplugin: avoid setContextProperty
Change-Id: I5bebe3b50afc1dba39b73bd54679ef91b2a9ba8d
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-10-07 07:51:42 +02:00
Simon Hausmann 83be211744 Merge remote-tracking branch 'origin/wip/qt6' into dev
Change-Id: I10c4b7fcfa0397d999d45e310c2f8f051d57d4d2
2019-09-19 08:53:00 +02:00
Michael Brasser 8cfd5fde29 Also check the non-file-imported type on QQmlMetaType::typeForUrl
There is no reason why we wouldn't want to find those. Failure to do so
leads to duplicate creation of singleton objects.

Fixes: QTBUG-76514
Change-Id: If2fdfbd933229518136ae0d19474bbaebfbb8cff
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Michael Brasser <michael.brasser@live.com>
2019-09-09 11:16:06 +02:00
Simon Hausmann 880a143eb5 Merge remote-tracking branch 'origin/dev' into wip/qt6
Change-Id: I4476733af61fcf3a2af1d121a4585c3fae1c240e
2019-07-12 20:36:48 +02:00
Friedemann Kleint 83f8d886ce Fix some compiler warnings in tests
- Signedness of integer comparison
- Unused parameters and variables
- Ignored return values of QTest::qWaitForWindowExposed() (nodiscard)
- float to int conversions

Change-Id: Ibece620d3c980a5af3b7717486c841d8072ed8af
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2019-07-12 16:00:51 +02:00
Alexandru Croitor 19138e6d99 Fix QStaticPlugin Qt6 usage in test
Also added QtQml import for Component.onCompleted.

Change-Id: Ic54a7827c82b8dfd7a1b2f36af4d944bae54bdec
Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
2019-07-08 17:17:43 +02:00
Ulf Hermann ac6e893c5c Make the shared test code independent of QtQml
This enables us to drop the QML dependency from a number of tests. This
is desirable because we want to test that we didn't do any incompatible
changes to the debug framework.

Change-Id: I937dd45d3079eac15c200c9d68bb4c911f61afc0
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2018-04-24 19:24:12 +00:00
Shawn Rutledge 499ec43937 use nullptr consistently (clang-tidy)
From now on we prefer nullptr instead of 0 to clarify cases where
we are assigning or testing a pointer rather than a numeric zero.

Also, replaced cases where 0 was passed as Qt::KeyboardModifiers
with Qt::NoModifier (clang-tidy replaced them with nullptr, which
waas wrong, so it was just as well to make the tests more readable
rather than to revert those lines).

Change-Id: I4735d35e4d9f42db5216862ce091429eadc6e65d
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2018-02-26 07:13:18 +00:00
Liang Qi 4d525de33e Merge remote-tracking branch 'origin/5.10' into 5.11
Conflicts:
	src/imports/shapes/qquickshape.cpp
	src/imports/shapes/qquickshape_p_p.h
	src/qml/compiler/qqmlpropertycachecreator_p.h
	src/qml/jsruntime/qv4value_p.h
	src/quick/items/qquickloader_p.h
	tests/auto/qml/qqmlecmascript/tst_qqmlecmascript.cpp
	tools/qmlprofiler/qmlprofilerapplication.cpp

Change-Id: Iafc66ae84bf78630ed72a986acb678e9d19e3a69
2018-02-12 16:31:13 +01:00
Simon Hausmann 61a32b78db Lift restriction for type registrations in QML module plugins
During the registerTypes() callback in a QML module plugin we only allow
types to be registered that match the module URI specified in the
qmldir.

We can observe in QtQuickControls 2 that sometimes we need to register
types outside of the namespace of the module itself. QQC2 is in
QtQuick.Controls but the module has internal types that are in
QtQuick.Controls.impl.

Types are intended to be registered once in the virtual registerTypes()
function. However as we don't allow for the registration of .impl to
happen in registerTypes(), QQC2 works around this by registering the
types in initializeEngine(), during which the namespace restriction is
not in place.

This workaround means that every time an application creates a
QQuickView (and thus new QML engine) and loads a QML file that imports
QQC2, we end up calling initializeEngine(), as opposed to
registerTypes() that is called only one single time in the application
process. As a consequence each time this happens we and up calling
qmlRegisterTypes() with the same times and leak memory this way, as
qmlRegisterType*() is supposed to register a new type and return a new
type id that can be passed to qmlUnregisterType.

To solve this this patch lifts the restriction on namespaces for
registered types during registerTypes(). The real world case of QQC2
shows that the restriction is limiting and also easy to work around.
With the restriction lifted QQC2 can now register all types once in
registerTypes() instead.

[ChangeLog][QtQml][Important Behavior Changes] QML module plugins used
to be limited to type registrations in the primary module namespace in
the virtual registerTypes() function. Module authors worked around this
limitation by placing necessary internal type registrations into
initializeEngine() that may cause memory leaks. Therefore this
restriction has been moved and types in any (non-protected) namespaces
can be registered in the registerTypes() function.

Change-Id: I5baf9718a0b0a591f6eb6d7e2dc83e13b204800d
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
2018-02-02 09:50:13 +00:00
Simon Hausmann 8c05018557 Fix dead lock / race in QML type loader when importing plugins
When importing modules - in the QML loader thread - with plugins we keep
globally track of the Qt plugins that we have loaded that contain QML
modules, to ensure that we don't call the engine-independent
registerTypes() function on the plugin multiple times. After
registerTypes() we may also call initializeEngine() on the plugin for
the engine-specific initialization, which - as a QQmlEngine is provided
as parameter - must happen in the gui thread. For that we issue a
thread-blocking call that waits until the gui thread has woken up and
processed the event/call.

During that time the global plugin lock is held by that QML loader
thread.

If meanwhile the gui thread instantiates a second QQmlEngine and
attempts to issue a synchronous type compilation (using
QQmlComponent::CompilationMode::PreferSynchronous), then gui thread is
blocking and waiting for its own QML loader thread to complete the type
compilation, which may involve processing an import that requires
loading a plugin. Now this second QML loader thread is blocked by trying
to acquire the global plugin registry lock
(qmlEnginePluginsWithRegisteredTypes()->mutex) in qqmlimports.cpp.

Now the first QML loader thread is blocked because the gui thread is not
processing the call events for the first engine. The gui thread is
blocked waiting for the second QML loader thread, which in turn is stuck
trying to acquire the lock held by the first QML loader thread.

The provided test case triggers this scenario, although through a
slightly different way. It's not possible to wait in the gui thread for
the plugin lock to be held in a loader thread via the registerTypes
callback, as that also acquires the QQmlMetaType lock that will
interfere with the test-case. However the same plugin lock issue appears
when the first QML engine is located in a different thread altogether.
In that case the dispatch to the engine thread /works/, but it won't be
the gui thread but instead the secondary helper thread of the test case
that will sit in our initializeEngine() callback.

This bug was spotted in production customer code with backtraces
pointing into the three locations described above: One QML loader thread
blocking on a call to the gui thread, the gui thread blocking on a
second QML loader thread and that one blocking on acquisition of the
plugin lock held by the first.

Fortunately it is not necessary to hold on to the global plugin lock
when doing the engine specific initialization. That allows the second
QML loader thread to complete its work and finally resume the GUI
thread's event loop.

Change-Id: If757b3fc9b473f42b266427e55d7a1572b937515
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
2018-02-02 05:46:05 +00:00
J-P Nurmi c56cc0c6c2 Introduce qmlRegisterModule()
This is particularly useful for keeping the versions of related modules in
sync. For example, when QtQuick.Controls introduces new types or revisions
and bumps up the minor version, qmlRegisterModule() can be used to make the
same version available for QtQuick.Controls.Styles in case it doesn't have
new types or revisions to register.

[ChangeLog][QtQml] Introduced qmlRegisterModule() that can be used to
make a certain module version available, even if no types or revisions
are registered for that version.

Change-Id: I5ec457465cd778bb0adda55771d195f69cd4b31a
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2016-11-18 18:57:53 +00:00
J-P Nurmi 3c5e438890 Allow target path version in a parent module
For example, the QML Engine is now able to locate QtQml.Models 2.x
in both of the following target/installation paths:

- QT_INSTALL_QML/QtQml/Models.2
- QT_INSTALL_QML/QtQml.2/Models

This is required for QtQuick Controls 2. The target path of the module
is QT_INSTALL_QML/QtQuick/Controls.2. The built-in styles are installed
as sub-directories to be able to locate them from the controls module.

Some of the built-in styles provide their own C++ extensions via style-
specific imports (eg. the Material attached property is imported from
QtQuick.Controls.Material 2.0). The problem is that the QML Engine does
not find the module from QT_INSTALL_QML/QtQuick/Controls.2/Material,
but requires it to be installed outside the main controls module ie.
QT_INSTALL_QML/QtQuick/Controls/Material(.2). This makes it a) hard to
locate the styles from the main controls module, and b) conflicts with
the target path of QtQuick Controls 1.

[ChangeLog][QtQml] Made the QML Engine capable of locating QML sub-
modules from within a versioned parent module path. For example,
QtQml.Models 2.x can be either in QT_INSTALL_QML/QtQml/Models.2 or
in QT_INSTALL_QML/QtQml.2/Models.

Change-Id: I2fe4bbdd6d04dd1e80cbe9b3e7e02617658a0756
Task-number: QTBUG-52556
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2016-04-21 09:32:25 +00:00
Jani Heikkinen 38ec3bd755 Updated license headers
From Qt 5.7 -> tools & applications are lisenced under GPL v3 with some
exceptions, see
http://blog.qt.io/blog/2016/01/13/new-agreement-with-the-kde-free-qt-foundation/

Updated license headers to use new GPL-EXCEPT header instead of LGPL21 one
(in those files which will be under GPL 3 with exceptions)

Change-Id: I04760a0801837cfc516d1c7c02d4f503f6bb70b6
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
2016-01-20 11:46:25 +00:00
Ulf Hermann 35da68a15c Provide a threaded TestHTTPServer
This allows us to do blocking operations that interact with the test
server in the main thread. The threaded server is used in tests that
don't explicitly require asynchronous operation.

Change-Id: Ibcb28e79a1114cb9cfb812e86aae0a1af71c569e
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2015-10-14 08:03:38 +00:00
Friedemann Kleint 0f5a721761 Tests: Fix single-character string literals.
Use character literals where applicable.

Change-Id: Ib0e618752fbc762a73a0a91c43efab61ef2c9687
Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2015-10-13 14:24:16 +00:00
Simon Hausmann e2447f9f5f Merge remote-tracking branch 'origin/5.4' into 5.5
Conflicts:
	.qmake.conf
	tests/auto/qml/qqmlxmlhttprequest/tst_qqmlxmlhttprequest.cpp

Change-Id: I715b8a78b74cbe0dcaf599367fd6e08af4858e11
2015-04-27 14:40:00 +02:00
Simon Hausmann 79d56651ed Prospective fix for flakey "network" related QML tests
Replace hard-coded server ports with dynamically allocated ports.

Change-Id: Iab8f9a88343a9f2c49af3cd700c954c13c3bf121
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
2015-04-25 12:02:55 +00:00
Jani Heikkinen c5796292ad Update copyright headers
Qt copyrights are now in The Qt Company, so we could update the source
code headers accordingly. In the same go we should also fix the links to
point to qt.io.

Change-Id: I61120571787870c0ed17066afb31779b1e6e30e9
Reviewed-by: Iikka Eklund <iikka.eklund@theqtcompany.com>
2015-02-12 10:28:11 +00:00
J-P Nurmi 5cb8ca29c3 Allow importing protected modules with different major versions
This allows QtQuick.Controls 1.x and 2.x imports to co-exist even
if they are two different plugins with the same module directive.

Change-Id: Idee302439e3c2fd6813ba2f41b69144fbae7902c
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
2015-01-08 11:12:56 +01:00
Jani Heikkinen e7ceacda70 Update license headers and add new licenses
- Renamed LICENSE.LGPL to LICENSE.LGPLv21
- Added LICENSE.LGPLv3 & LICENSE.GPLv2
- Removed LICENSE.GPL

Change-Id: I84a565e2e0caa3b76bf291a7d188a57a4b00e1b0
Reviewed-by: Jani Heikkinen <jani.heikkinen@digia.com>
2014-08-25 11:28:46 +02:00
Robin Burchell aa578c4e29 TestHTTPServer: Make listening an explicit operation that reports failure.
Use this to print the error message when listening fails, and switch to always
stack allocating TestHTTPServer instances for easier cleanup.

Change-Id: I63b2bd38963b66611dc08a5c322615d91a91e675
Reviewed-by: John Brooks <john.brooks@dereferenced.net>
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Reviewed-by: Lorn Potter <lorn.potter@jollamobile.com>
2014-03-21 00:09:29 +01:00
Simon Hausmann 2f3f19e6f7 Prospective iOS build fix for tst_qqmlmoduleplugin
Include unistd.h for _PC_CASE_SENSITIVE

Change-Id: I0c57d7d84fa4c7379502dbf95fd22476724d5fa3
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2014-02-16 16:06:31 +01:00
Oswald Buddenhagen e2ea0a83cc fix whitespace
remove trailing spaces and expand tabs

Change-Id: Ieacb9d096b612c45d1a64700044c114d1f7522bc
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
2014-01-22 21:01:53 +01:00
Liang Qi 50a3ddcbbf tests: fix tst_qqmlmoduleplugin::incorrectPluginCase()
It gives different error message based on the case sensitivity of
the file system on Mac.

Task-number: QTBUG-32652
Change-Id: I52415126e63978c9f80b7652e0116e0e07703fd8
Reviewed-by: Liang Qi <liang.qi@digia.com>
2013-11-01 21:18:56 +01:00
Liang Qi 7d850df7e6 tests: replace nokia with qtproject in tst_qqmlmoduleplugin
Change-Id: I674da7f77dde380fb0772d5077da84de875b6ce8
Reviewed-by: Alan Alpert <aalpert@blackberry.com>
2013-10-31 20:16:11 +01:00
Sergio Ahumada 19d6806716 tests: Replace Q_OS_MACX -> Q_OS_OSX
Use the correct identifier for the OS X operating system.

Change-Id: Iff433d312c7c808ddce13466be3db628cf3a9890
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
2013-10-21 11:56:22 +02:00
Alan Alpert fee79b7077 Add qmlProtectModule
A C++ analog to the protected qmldir syntax, this is also a potential
performance improvement because we can avoid some file system accesses.

Change-Id: I41781a6cc72aa65bd2d397800345ea16ef442e90
Reviewed-by: Antti Piira <apiira@blackberry.com>
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
2013-09-20 01:09:05 +02:00
Frederik Gladhorn d2628d9d70 Merge remote-tracking branch 'origin/stable' into dev
Conflicts:
	tests/auto/quick/qquickgridview/qquickgridview.pro
	tests/auto/quick/qquickitem/qquickitem.pro

Change-Id: Ic54cafbdda1ac22757d2ee65dcc63a1b167c7556
2013-08-19 09:47:35 +02:00
Sergio Ahumada 26239ffbfd test: Mark tst_qqmlmoduleplugin::incorrectPluginCase() as XFAIL
Mark incorrectPluginCase() as expected failure on OS X 10.8

Task-number: QTBUG-32652
Change-Id: I8fd2c0ceacabfc74defe84fc6538b268145c5110
Reviewed-by: Simo Fält <simo.falt@digia.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
2013-08-13 21:42:59 +02:00