Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Building test fails? #59

Closed
Bubblestun opened this issue May 30, 2020 · 2 comments
Closed

Building test fails? #59

Bubblestun opened this issue May 30, 2020 · 2 comments

Comments

@Bubblestun
Copy link

[OK ]cd C:\path\to\folder\with\qtcsv

[OK ]# Create build directory
[OK ]mkdir .\build
[OK ]cd .\build

[OK ]# Build library. You can choose build type: release or debug. Set DESTDIR to current directory.
[OK ]qmake ..\qtcsv.pro CONFIG+=[release|debug] DESTDIR=%cd%
[OK ]mingw32-make

[OK ]# Create build directory for tests
[OK ]mkdir .\tests
[OK ]cd .\tests

[OK ]# Copy library file into 'tests' directory
[OK ]copy ..\qtcsv.dll .\

[OK ]# Build tests
[OK ]qmake ....\tests\tests.pro CONFIG+=[release|debug] DESTDIR=%cd%
[ERROR]mingw32-make

..\..\tests\testreader.cpp: In member function 'void TestReader::testReadFileWorldCitiesPop()':
..\..\tests\testreader.cpp:383:17: error: 'void QTime::start()' is deprecated: Use QElapsedTimer instead [-Werror=deprecated-declarations]
     timer.start();
                 ^
In file included from C:\Qt\5.14.2\mingw73_32\include/QtCore/qcborvalue.h:44:0,
                 from C:\Qt\5.14.2\mingw73_32\include/QtCore/qcborarray.h:43,
                 from C:\Qt\5.14.2\mingw73_32\include/QtCore/QtCore:38,
                 from C:\Qt\5.14.2\mingw73_32\include/QtTest/QtTestDepends:3,
                 from C:\Qt\5.14.2\mingw73_32\include\QtTest/QtTest:3,
                 from ..\..\tests\testreader.h:5,
                 from ..\..\tests\testreader.cpp:1:
C:\Qt\5.14.2\mingw73_32\include/QtCore/qdatetime.h:228:55: note: declared here
     QT_DEPRECATED_X("Use QElapsedTimer instead") void start();
                                                       ^~~~~
..\..\tests\testreader.cpp:385:50: error: 'int QTime::elapsed() const' is deprecated: Use QElapsedTimer instead [-Werror=deprecated-declarations]
     qDebug() << "Elapsed time:" << timer.elapsed() << "ms";
                                                  ^
In file included from C:\Qt\5.14.2\mingw73_32\include/QtCore/qcborvalue.h:44:0,
                 from C:\Qt\5.14.2\mingw73_32\include/QtCore/qcborarray.h:43,
                 from C:\Qt\5.14.2\mingw73_32\include/QtCore/QtCore:38,
                 from C:\Qt\5.14.2\mingw73_32\include/QtTest/QtTestDepends:3,
                 from C:\Qt\5.14.2\mingw73_32\include\QtTest/QtTest:3,
                 from ..\..\tests\testreader.h:5,
                 from ..\..\tests\testreader.cpp:1:
C:\Qt\5.14.2\mingw73_32\include/QtCore/qdatetime.h:230:54: note: declared here
     QT_DEPRECATED_X("Use QElapsedTimer instead") int elapsed() const;
                                                      ^~~~~~~
cc1plus.exe: all warnings being treated as errors
mingw32-make[1]: *** [Makefile.Release:2670: release/testreader.o] Error 1
mingw32-make[1]: Leaving directory 'D:/APP/qtcsv-master/build/tests'
mingw32-make: *** [Makefile:45: release] Error 2
@iamantony
Copy link
Owner

Hi @Bubblestun. Thanks for the info. Issue was fixed in 1b0ee01. Please verify on your side that code from master branch could be build with Qt 5.14 without warnings about QTime deprecation.

@Bubblestun
Copy link
Author

Bubblestun commented Jun 1, 2020

I can confirm the issue is fixed.
It builds on 5.14 without warnings.
Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants