Skip to content

Commit fb95cc2

Browse files
author
build
committed
Merge branch 'WD_1.X_dev' of https://portal-ua.globallogic.com/git/wd into WD_1.X_dev
2 parents d0001a8 + b3d5ac0 commit fb95cc2

30 files changed

+2071
-745
lines changed

build_ios.sh

Lines changed: 24 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,21 +3,38 @@
33
export QT_DIR=/usr/local/opt/qt5_ios
44
export PATH=$QT_DIR/bin:$PATH
55

6+
cat > wd.gypi <<EOF
7+
{
8+
'variables':
9+
{
10+
'QT5': '1',
11+
'QT_BIN_PATH': '${QT_DIR}/bin',
12+
'QT_INC_PATH': '${QT_DIR}/include',
13+
'QT_LIB_PATH': '${QT_DIR}/lib',
14+
'WD_CONFIG_WEBKIT': '0',
15+
'WD_CONFIG_QUICK': '1',
16+
'WD_CONFIG_PLAYER': '1',
17+
'WD_BUILD_MONGOOSE': '1',
18+
},
19+
}
20+
EOF
21+
622
python generate_wdversion.py
723

824
gyp --depth . -G output_dir=. -D platform=desktop -D mode=debug -f xcode -D OS=ios --generator-output=out/ wd.gyp
925

1026
if [ "$1" == "-all" ]
1127
then
1228

13-
xcodebuild -project out/wd_test.xcodeproj -target test_ios_WD -arch i386 -sdk iphonesimulator clean build
14-
15-
cd ./platform/ios/wd
16-
qmake wd.pro -r -spec unsupported/macx-iossimulator-clang CONFIG+=x86
17-
make -release
29+
#xcodebuild -project out/wd_test.xcodeproj -target test_ios_WD -arch i386 -sdk iphonesimulator #clean build
30+
xcodebuild -project out/base.xcodeproj -target chromium_base -arch i386 -sdk iphonesimulator clean build
31+
xcodebuild -project out/wd_core.xcodeproj -target WebDriver_core -arch i386 -sdk iphonesimulator clean build
32+
xcodebuild -project out/wd_ext_qt.xcodeproj -target WebDriver_extension_qt_base -arch i386 -sdk iphonesimulator clean build
33+
xcodebuild -project out/wd_ext_qt.xcodeproj -target WebDriver_extension_qt_quick -arch i386 -sdk iphonesimulator clean build
1834

19-
cd ../wd_test
2035

21-
xcodebuild -project wd_test.xcodeproj -alltargets -arch i386 -sdk iphonesimulator -configuration Debug ONLY_ACTIVE_ARCH=NO VALID_ARCHS="armv7 i386" clean build
36+
cd ./platform/ios/wd
37+
qmake wd.pro -r -spec macx-ios-clang CONFIG+=x86 CONFIG+=iphonesimulator CONFIG+=release
38+
make
2239

2340
fi

platform/ios/.gitignore

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,17 @@ xcuserdata/
1818
#Python modules
1919
MANIFEST
2020
dist/
21-
build/
21+
build*
2222

2323
# Backup files
2424
*~.nib
2525

2626
DerivedData/
27-
build*/
28-
29-
Makefile
27+
ui_*
28+
Release*
29+
Debug*
30+
*.xcodeproj
31+
Makefile*
32+
Info.plist
33+
*stash
3034

platform/ios/Readme_qt5.txt

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,17 @@
11
Minumum Requirements
22
---------------------
33
* Qt iOS X install:
4-
Download iOS QT package from http://www.mediator-software.com
5-
and select "Qt 5.1.0 for iPhone 3GS (and later)*" to download Qt4iOS-SDK-5.1.0-7Jul13.zip.
6-
Unzip it an follow by instructions from Qt4iOS-Installation-Guide.pdf to install Qt 5.1.0
4+
Please note that QT library is needed for developing only. If you want just run application on iOs simulator you may skip this step.
5+
Latest WebDriver test application is based on Qt 5.2.0. You may install it by image from http://download.qt-project.org/official_releases/qt/5.2/5.2.0/qt-mac-opensource-5.2.0-ios-x86_64-offline.dmg.
6+
77

88
Setup:
99
------
10-
In command prompt run iPhone simulator with WebDriver application (wd_test.app) e.g.
10+
In command prompt run iOS simulator with WebDriver application (wd.app) e.g.
11+
ios-sim launch ./wd.app
12+
13+
By default device family is iPhone. In order to run iPad simulator just run ios-sim with --family argument e.g.
14+
ios-sim launch ./wd.app --family ipad
1115

12-
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Applications/iPhone\ Simulator.app/Contents/MacOS/iPhone\ Simulator -SimulateApplication /Users/build/GIT/wd_ios/platform/ios/wd_test/build/Debug-iphonesimulator/wd_test.app/wd_test
16+
In order to add argument to WebDriver just use --args. For example, VideoTests require video file placed in WD repository:
17+
ios-sim launch ./wd.app --args --test_data_folder=/Users/build/git/wd/test_data

platform/ios/wd/wd.pro

Lines changed: 26 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
1-
QT += core gui network
1+
QT += core gui network widgets qml xml multimedia multimediawidgets quick
2+
3+
TEMPLATE = app
4+
QTPLUGIN += qtaudio_coreaudio qtmedia_audioengine qavfmediaplayer qavfcamera
5+
CONFIG += mobility
26

37
SOURCES += \
48
../../../src/Test/shutdown_command.cc \
@@ -19,7 +23,10 @@ SOURCES += \
1923
../../../src/Test/ClickTest.cc \
2024
../../../src/Test/ClickScrollingTest.cc \
2125
../../../src/Test/BasicMouseInterfaceTest.cc \
22-
../../../src/Test/BasicKeyboardInterfaceTest.cc
26+
../../../src/Test/BasicKeyboardInterfaceTest.cc \
27+
../../../src/Test/TouchTest.cc \
28+
../../../src/Test/MenuTest.cc \
29+
../../../src/Test/VideoTest.cc
2330

2431
HEADERS += \
2532
../../../src/Test/shutdown_command.h \
@@ -40,20 +47,34 @@ HEADERS += \
4047
../../../src/Test/ClickTest.h \
4148
../../../src/Test/ClickScrollingTest.h \
4249
../../../src/Test/BasicMouseInterfaceTest.h \
43-
../../../src/Test/BasicKeyboardInterfaceTest.h
50+
../../../src/Test/BasicKeyboardInterfaceTest.h \
51+
../../../src/Test/TouchTest.h \
52+
../../../src/Test/MenuTest.h \
53+
../../../src/Test/VideoTest.h
4454

4555
INCLUDEPATH += ../../../inc
46-
INCLUDEPATH += ../../../mocs
4756

4857
FORMS += \
4958
../../../src/Test/ElementSelectingTest.ui \
5059
../../../src/Test/ClickScrollingTest.ui
5160

61+
DEFINES += WD_ENABLE_PLAYER="1"
5262

5363
DESTDIR = build
5464
OBJECTS_DIR = build
5565
MOC_DIR = build
5666

57-
ios: include($$[QT_HOST_DATA/get]/mkspecs/common/ios/qiosapp.conf)
67+
INCLUDEPATH += $$PWD/../../../build/Default-iphonesimulator
68+
DEPENDPATH += $$PWD/../../../build/Default-iphonesimulator
69+
70+
LIBS += -L$$PWD/../../../build/Default-iphonesimulator/ -lchromium_base
71+
PRE_TARGETDEPS += $$PWD/../../../build/Default-iphonesimulator/libchromium_base.a
72+
73+
LIBS += -L$$PWD/../../../build/Default-iphonesimulator/ -lWebDriver_core
74+
PRE_TARGETDEPS += $$PWD/../../../build/Default-iphonesimulator/libWebDriver_core.a
5875

76+
LIBS += -L$$PWD/../../../build/Default-iphonesimulator/ -lWebDriver_extension_qt_base
77+
PRE_TARGETDEPS += $$PWD/../../../build/Default-iphonesimulator/libWebDriver_extension_qt_base.a
5978

79+
LIBS += -L$$PWD/../../../build/Default-iphonesimulator/ -lWebDriver_extension_qt_quick
80+
PRE_TARGETDEPS += $$PWD/../../../build/Default-iphonesimulator/libWebDriver_extension_qt_quick.a

platform/ios/wd/wd.qml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
/*
2+
imports.qml
3+
4+
Declaration of QML Imports
5+
required by project.
6+
7+
This is necessary if we want
8+
to keep qml files in a folder
9+
separate from .pro file because
10+
of the way qmlimportscanner works.
11+
If these imports are not declared,
12+
qmake will not recognize them,
13+
and QtQuick will not be packaged
14+
with statically built apps (i.e. iOS)
15+
and imported at runtime.
16+
17+
This must be kept in the same
18+
directory as your .pro file
19+
*/
20+
21+
import QtQuick 2.1
22+
import QtQuick.Controls 1.1
23+
import QtMultimedia 5.0
24+
25+
QtObject {}

platform/ios/wd_qt5.gypi

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
11
{
2-
'variables': {
3-
'QT5': '1', # change to '1' for enabling Qt5
2+
'variables':
3+
{
4+
'QT5': '1',
5+
'QT_BIN_PATH': '/usr/local/opt/qt5_ios/bin',
6+
'QT_INC_PATH': '/usr/local/opt/qt5_ios/include',
7+
'QT_LIB_PATH': '/usr/local/opt/qt5_ios/lib',
8+
'WD_CONFIG_WEBKIT': '0',
9+
'WD_CONFIG_QUICK': '1',
10+
'WD_CONFIG_PLAYER': '1',
411
'WD_BUILD_MONGOOSE': '1',
5-
'WD_CONFIG_PLAYER': '0',
6-
'QT_INC_PATH': '/usr/local/opt/qt5_ios/include',
7-
'QT_LIB_PATH': '/usr/local/opt/qt5_ios/lib',
8-
'QT_BIN_PATH': '/usr/local/opt/qt5_ios/bin',
912
},
1013
}

platform/ios/wd_qt5_64.gypi

Lines changed: 0 additions & 8 deletions
This file was deleted.

0 commit comments

Comments
 (0)