Jamon Holmgren 6 lat temu
rodzic
commit
ba4912595d
55 zmienionych plików z 12 dodań i 3120 usunięć
  1. 0
    3
      WebTest/.babelrc
  2. 0
    6
      WebTest/.buckconfig
  3. 0
    67
      WebTest/.flowconfig
  4. 0
    1
      WebTest/.gitattributes
  5. 0
    60
      WebTest/.gitignore
  6. 0
    1
      WebTest/.watchmanconfig
  7. 0
    49
      WebTest/App.js
  8. 0
    65
      WebTest/android/app/BUCK
  9. 0
    151
      WebTest/android/app/build.gradle
  10. 0
    17
      WebTest/android/app/proguard-rules.pro
  11. 0
    26
      WebTest/android/app/src/main/AndroidManifest.xml
  12. 0
    15
      WebTest/android/app/src/main/java/com/webtest/MainActivity.java
  13. 0
    47
      WebTest/android/app/src/main/java/com/webtest/MainApplication.java
  14. BIN
      WebTest/android/app/src/main/res/mipmap-hdpi/ic_launcher.png
  15. BIN
      WebTest/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
  16. BIN
      WebTest/android/app/src/main/res/mipmap-mdpi/ic_launcher.png
  17. BIN
      WebTest/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
  18. BIN
      WebTest/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
  19. BIN
      WebTest/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
  20. BIN
      WebTest/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
  21. BIN
      WebTest/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
  22. BIN
      WebTest/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
  23. BIN
      WebTest/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
  24. 0
    3
      WebTest/android/app/src/main/res/values/strings.xml
  25. 0
    8
      WebTest/android/app/src/main/res/values/styles.xml
  26. 0
    40
      WebTest/android/build.gradle
  27. 0
    20
      WebTest/android/gradle.properties
  28. BIN
      WebTest/android/gradle/wrapper/gradle-wrapper.jar
  29. 0
    5
      WebTest/android/gradle/wrapper/gradle-wrapper.properties
  30. 0
    164
      WebTest/android/gradlew
  31. 0
    90
      WebTest/android/gradlew.bat
  32. 0
    8
      WebTest/android/keystores/BUCK
  33. 0
    4
      WebTest/android/keystores/debug.keystore.properties
  34. 0
    5
      WebTest/android/settings.gradle
  35. 0
    4
      WebTest/app.json
  36. 0
    4
      WebTest/e2e/config.json
  37. 0
    19
      WebTest/e2e/init.js
  38. 0
    19
      WebTest/e2e/webTest.spec.js
  39. 0
    7
      WebTest/index.js
  40. 0
    54
      WebTest/ios/WebTest-tvOS/Info.plist
  41. 0
    24
      WebTest/ios/WebTest-tvOSTests/Info.plist
  42. 0
    1528
      WebTest/ios/WebTest.xcodeproj/project.pbxproj
  43. 0
    129
      WebTest/ios/WebTest.xcodeproj/xcshareddata/xcschemes/WebTest-tvOS.xcscheme
  44. 0
    129
      WebTest/ios/WebTest.xcodeproj/xcshareddata/xcschemes/WebTest.xcscheme
  45. 0
    14
      WebTest/ios/WebTest/AppDelegate.h
  46. 0
    35
      WebTest/ios/WebTest/AppDelegate.m
  47. 0
    42
      WebTest/ios/WebTest/Base.lproj/LaunchScreen.xib
  48. 0
    38
      WebTest/ios/WebTest/Images.xcassets/AppIcon.appiconset/Contents.json
  49. 0
    6
      WebTest/ios/WebTest/Images.xcassets/Contents.json
  50. 0
    56
      WebTest/ios/WebTest/Info.plist
  51. 0
    16
      WebTest/ios/WebTest/main.m
  52. 0
    24
      WebTest/ios/WebTestTests/Info.plist
  53. 0
    68
      WebTest/ios/WebTestTests/WebTestTests.m
  54. 0
    37
      WebTest/package.json
  55. 12
    12
      ios/RCTWKWebView.xcodeproj/project.pbxproj

+ 0
- 3
WebTest/.babelrc Wyświetl plik

@@ -1,3 +0,0 @@
1
-{
2
-  "presets": ["react-native"]
3
-}

+ 0
- 6
WebTest/.buckconfig Wyświetl plik

@@ -1,6 +0,0 @@
1
-
2
-[android]
3
-  target = Google Inc.:Google APIs:23
4
-
5
-[maven_repositories]
6
-  central = https://repo1.maven.org/maven2

+ 0
- 67
WebTest/.flowconfig Wyświetl plik

@@ -1,67 +0,0 @@
1
-[ignore]
2
-; We fork some components by platform
3
-.*/*[.]android.js
4
-
5
-; Ignore "BUCK" generated dirs
6
-<PROJECT_ROOT>/\.buckd/
7
-
8
-; Ignore unexpected extra "@providesModule"
9
-.*/node_modules/.*/node_modules/fbjs/.*
10
-
11
-; Ignore duplicate module providers
12
-; For RN Apps installed via npm, "Libraries" folder is inside
13
-; "node_modules/react-native" but in the source repo it is in the root
14
-.*/Libraries/react-native/React.js
15
-
16
-; Ignore polyfills
17
-.*/Libraries/polyfills/.*
18
-
19
-; Ignore metro
20
-.*/node_modules/metro/.*
21
-
22
-[include]
23
-
24
-[libs]
25
-node_modules/react-native/Libraries/react-native/react-native-interface.js
26
-node_modules/react-native/flow/
27
-node_modules/react-native/flow-github/
28
-
29
-[options]
30
-emoji=true
31
-
32
-module.system=haste
33
-module.system.haste.use_name_reducers=true
34
-# get basename
35
-module.system.haste.name_reducers='^.*/\([a-zA-Z0-9$_.-]+\.js\(\.flow\)?\)$' -> '\1'
36
-# strip .js or .js.flow suffix
37
-module.system.haste.name_reducers='^\(.*\)\.js\(\.flow\)?$' -> '\1'
38
-# strip .ios suffix
39
-module.system.haste.name_reducers='^\(.*\)\.ios$' -> '\1'
40
-module.system.haste.name_reducers='^\(.*\)\.android$' -> '\1'
41
-module.system.haste.name_reducers='^\(.*\)\.native$' -> '\1'
42
-module.system.haste.paths.blacklist=.*/__tests__/.*
43
-module.system.haste.paths.blacklist=.*/__mocks__/.*
44
-module.system.haste.paths.blacklist=<PROJECT_ROOT>/node_modules/react-native/Libraries/Animated/src/polyfills/.*
45
-module.system.haste.paths.whitelist=<PROJECT_ROOT>/node_modules/react-native/Libraries/.*
46
-
47
-munge_underscores=true
48
-
49
-module.name_mapper='^[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> 'RelativeImageStub'
50
-
51
-module.file_ext=.js
52
-module.file_ext=.jsx
53
-module.file_ext=.json
54
-module.file_ext=.native.js
55
-
56
-suppress_type=$FlowIssue
57
-suppress_type=$FlowFixMe
58
-suppress_type=$FlowFixMeProps
59
-suppress_type=$FlowFixMeState
60
-
61
-suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(<VERSION>\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)
62
-suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(<VERSION>\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+
63
-suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy
64
-suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError
65
-
66
-[version]
67
-^0.75.0

+ 0
- 1
WebTest/.gitattributes Wyświetl plik

@@ -1 +0,0 @@
1
-*.pbxproj -text

+ 0
- 60
WebTest/.gitignore Wyświetl plik

@@ -1,60 +0,0 @@
1
-# OSX
2
-#
3
-.DS_Store
4
-
5
-# Xcode
6
-#
7
-build/
8
-*.pbxuser
9
-!default.pbxuser
10
-*.mode1v3
11
-!default.mode1v3
12
-*.mode2v3
13
-!default.mode2v3
14
-*.perspectivev3
15
-!default.perspectivev3
16
-xcuserdata
17
-*.xccheckout
18
-*.moved-aside
19
-DerivedData
20
-*.hmap
21
-*.ipa
22
-*.xcuserstate
23
-project.xcworkspace
24
-
25
-# Android/IntelliJ
26
-#
27
-build/
28
-.idea
29
-.gradle
30
-local.properties
31
-*.iml
32
-
33
-# node.js
34
-#
35
-node_modules/
36
-npm-debug.log
37
-yarn-error.log
38
-
39
-# BUCK
40
-buck-out/
41
-\.buckd/
42
-*.keystore
43
-
44
-# fastlane
45
-#
46
-# It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the
47
-# screenshots whenever they are needed.
48
-# For more information about the recommended setup visit:
49
-# https://docs.fastlane.tools/best-practices/source-control/
50
-
51
-*/fastlane/report.xml
52
-*/fastlane/Preview.html
53
-*/fastlane/screenshots
54
-
55
-# Bundle artifact
56
-*.jsbundle
57
-
58
-# Don't save lockfiles for this test project
59
-package-lock.json
60
-yarn.lock

+ 0
- 1
WebTest/.watchmanconfig Wyświetl plik

@@ -1 +0,0 @@
1
-{}

+ 0
- 49
WebTest/App.js Wyświetl plik

@@ -1,49 +0,0 @@
1
-/**
2
- * Sample React Native App
3
- * https://github.com/facebook/react-native
4
- *
5
- * @format
6
- */
7
-
8
-import React, { Component } from 'react';
9
-import { Platform, StyleSheet, Text, View } from 'react-native';
10
-import { WebView } from 'react-native-webview'
11
-
12
-const instructions = Platform.select({
13
-  ios: 'Press Cmd+R to reload,\n' + 'Cmd+D or shake for dev menu',
14
-  android:
15
-    'Double tap R on your keyboard to reload,\n' +
16
-    'Shake or press menu button for dev menu',
17
-});
18
-
19
-export default class App extends Component {
20
-  render() {
21
-    return (
22
-      <View testID="welcome" style={styles.container}>
23
-        <Text style={styles.welcome}>Welcome to React Native!</Text>
24
-        <WebView
25
-          testID="testWebView"
26
-          style={styles.webview}
27
-          src={{ uri: "https://www.facebook.com/Engineering/" }}
28
-        />
29
-      </View>
30
-    );
31
-  }
32
-}
33
-
34
-const styles = StyleSheet.create({
35
-  container: {
36
-    flex: 1,
37
-    justifyContent: 'center',
38
-    alignItems: 'center',
39
-    backgroundColor: '#F5FCFF',
40
-  },
41
-  welcome: {
42
-    fontSize: 20,
43
-    textAlign: 'center',
44
-    margin: 10,
45
-  },
46
-  webview: {
47
-    marginBottom: 5,
48
-  },
49
-});

+ 0
- 65
WebTest/android/app/BUCK Wyświetl plik

@@ -1,65 +0,0 @@
1
-# To learn about Buck see [Docs](https://buckbuild.com/).
2
-# To run your application with Buck:
3
-# - install Buck
4
-# - `npm start` - to start the packager
5
-# - `cd android`
6
-# - `keytool -genkey -v -keystore keystores/debug.keystore -storepass android -alias androiddebugkey -keypass android -dname "CN=Android Debug,O=Android,C=US"`
7
-# - `./gradlew :app:copyDownloadableDepsToLibs` - make all Gradle compile dependencies available to Buck
8
-# - `buck install -r android/app` - compile, install and run application
9
-#
10
-
11
-lib_deps = []
12
-
13
-for jarfile in glob(['libs/*.jar']):
14
-  name = 'jars__' + jarfile[jarfile.rindex('/') + 1: jarfile.rindex('.jar')]
15
-  lib_deps.append(':' + name)
16
-  prebuilt_jar(
17
-    name = name,
18
-    binary_jar = jarfile,
19
-  )
20
-
21
-for aarfile in glob(['libs/*.aar']):
22
-  name = 'aars__' + aarfile[aarfile.rindex('/') + 1: aarfile.rindex('.aar')]
23
-  lib_deps.append(':' + name)
24
-  android_prebuilt_aar(
25
-    name = name,
26
-    aar = aarfile,
27
-  )
28
-
29
-android_library(
30
-    name = "all-libs",
31
-    exported_deps = lib_deps,
32
-)
33
-
34
-android_library(
35
-    name = "app-code",
36
-    srcs = glob([
37
-        "src/main/java/**/*.java",
38
-    ]),
39
-    deps = [
40
-        ":all-libs",
41
-        ":build_config",
42
-        ":res",
43
-    ],
44
-)
45
-
46
-android_build_config(
47
-    name = "build_config",
48
-    package = "com.webtest",
49
-)
50
-
51
-android_resource(
52
-    name = "res",
53
-    package = "com.webtest",
54
-    res = "src/main/res",
55
-)
56
-
57
-android_binary(
58
-    name = "app",
59
-    keystore = "//android/keystores:debug",
60
-    manifest = "src/main/AndroidManifest.xml",
61
-    package_type = "debug",
62
-    deps = [
63
-        ":app-code",
64
-    ],
65
-)

+ 0
- 151
WebTest/android/app/build.gradle Wyświetl plik

@@ -1,151 +0,0 @@
1
-apply plugin: "com.android.application"
2
-
3
-import com.android.build.OutputFile
4
-
5
-/**
6
- * The react.gradle file registers a task for each build variant (e.g. bundleDebugJsAndAssets
7
- * and bundleReleaseJsAndAssets).
8
- * These basically call `react-native bundle` with the correct arguments during the Android build
9
- * cycle. By default, bundleDebugJsAndAssets is skipped, as in debug/dev mode we prefer to load the
10
- * bundle directly from the development server. Below you can see all the possible configurations
11
- * and their defaults. If you decide to add a configuration block, make sure to add it before the
12
- * `apply from: "../../node_modules/react-native/react.gradle"` line.
13
- *
14
- * project.ext.react = [
15
- *   // the name of the generated asset file containing your JS bundle
16
- *   bundleAssetName: "index.android.bundle",
17
- *
18
- *   // the entry file for bundle generation
19
- *   entryFile: "index.android.js",
20
- *
21
- *   // whether to bundle JS and assets in debug mode
22
- *   bundleInDebug: false,
23
- *
24
- *   // whether to bundle JS and assets in release mode
25
- *   bundleInRelease: true,
26
- *
27
- *   // whether to bundle JS and assets in another build variant (if configured).
28
- *   // See http://tools.android.com/tech-docs/new-build-system/user-guide#TOC-Build-Variants
29
- *   // The configuration property can be in the following formats
30
- *   //         'bundleIn${productFlavor}${buildType}'
31
- *   //         'bundleIn${buildType}'
32
- *   // bundleInFreeDebug: true,
33
- *   // bundleInPaidRelease: true,
34
- *   // bundleInBeta: true,
35
- *
36
- *   // whether to disable dev mode in custom build variants (by default only disabled in release)
37
- *   // for example: to disable dev mode in the staging build type (if configured)
38
- *   devDisabledInStaging: true,
39
- *   // The configuration property can be in the following formats
40
- *   //         'devDisabledIn${productFlavor}${buildType}'
41
- *   //         'devDisabledIn${buildType}'
42
- *
43
- *   // the root of your project, i.e. where "package.json" lives
44
- *   root: "../../",
45
- *
46
- *   // where to put the JS bundle asset in debug mode
47
- *   jsBundleDirDebug: "$buildDir/intermediates/assets/debug",
48
- *
49
- *   // where to put the JS bundle asset in release mode
50
- *   jsBundleDirRelease: "$buildDir/intermediates/assets/release",
51
- *
52
- *   // where to put drawable resources / React Native assets, e.g. the ones you use via
53
- *   // require('./image.png')), in debug mode
54
- *   resourcesDirDebug: "$buildDir/intermediates/res/merged/debug",
55
- *
56
- *   // where to put drawable resources / React Native assets, e.g. the ones you use via
57
- *   // require('./image.png')), in release mode
58
- *   resourcesDirRelease: "$buildDir/intermediates/res/merged/release",
59
- *
60
- *   // by default the gradle tasks are skipped if none of the JS files or assets change; this means
61
- *   // that we don't look at files in android/ or ios/ to determine whether the tasks are up to
62
- *   // date; if you have any other folders that you want to ignore for performance reasons (gradle
63
- *   // indexes the entire tree), add them here. Alternatively, if you have JS files in android/
64
- *   // for example, you might want to remove it from here.
65
- *   inputExcludes: ["android/**", "ios/**"],
66
- *
67
- *   // override which node gets called and with what additional arguments
68
- *   nodeExecutableAndArgs: ["node"],
69
- *
70
- *   // supply additional arguments to the packager
71
- *   extraPackagerArgs: []
72
- * ]
73
- */
74
-
75
-project.ext.react = [
76
-    entryFile: "index.js"
77
-]
78
-
79
-apply from: "../../node_modules/react-native/react.gradle"
80
-
81
-/**
82
- * Set this to true to create two separate APKs instead of one:
83
- *   - An APK that only works on ARM devices
84
- *   - An APK that only works on x86 devices
85
- * The advantage is the size of the APK is reduced by about 4MB.
86
- * Upload all the APKs to the Play Store and people will download
87
- * the correct one based on the CPU architecture of their device.
88
- */
89
-def enableSeparateBuildPerCPUArchitecture = false
90
-
91
-/**
92
- * Run Proguard to shrink the Java bytecode in release builds.
93
- */
94
-def enableProguardInReleaseBuilds = false
95
-
96
-android {
97
-    compileSdkVersion rootProject.ext.compileSdkVersion
98
-    buildToolsVersion rootProject.ext.buildToolsVersion
99
-
100
-    defaultConfig {
101
-        applicationId "com.webtest"
102
-        minSdkVersion rootProject.ext.minSdkVersion
103
-        targetSdkVersion rootProject.ext.targetSdkVersion
104
-        versionCode 1
105
-        versionName "1.0"
106
-        ndk {
107
-            abiFilters "armeabi-v7a", "x86"
108
-        }
109
-    }
110
-    splits {
111
-        abi {
112
-            reset()
113
-            enable enableSeparateBuildPerCPUArchitecture
114
-            universalApk false  // If true, also generate a universal APK
115
-            include "armeabi-v7a", "x86"
116
-        }
117
-    }
118
-    buildTypes {
119
-        release {
120
-            minifyEnabled enableProguardInReleaseBuilds
121
-            proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
122
-        }
123
-    }
124
-    // applicationVariants are e.g. debug, release
125
-    applicationVariants.all { variant ->
126
-        variant.outputs.each { output ->
127
-            // For each separate APK per architecture, set a unique version code as described here:
128
-            // http://tools.android.com/tech-docs/new-build-system/user-guide/apk-splits
129
-            def versionCodes = ["armeabi-v7a":1, "x86":2]
130
-            def abi = output.getFilter(OutputFile.ABI)
131
-            if (abi != null) {  // null for the universal-debug, universal-release variants
132
-                output.versionCodeOverride =
133
-                        versionCodes.get(abi) * 1048576 + defaultConfig.versionCode
134
-            }
135
-        }
136
-    }
137
-}
138
-
139
-dependencies {
140
-    compile project(':react-native-webview')
141
-    compile fileTree(dir: "libs", include: ["*.jar"])
142
-    compile "com.android.support:appcompat-v7:${rootProject.ext.supportLibVersion}"
143
-    compile "com.facebook.react:react-native:+"  // From node_modules
144
-}
145
-
146
-// Run this once to be able to run the application with BUCK
147
-// puts all compile dependencies into folder libs for BUCK to use
148
-task copyDownloadableDepsToLibs(type: Copy) {
149
-    from configurations.compile
150
-    into 'libs'
151
-}

+ 0
- 17
WebTest/android/app/proguard-rules.pro Wyświetl plik

@@ -1,17 +0,0 @@
1
-# Add project specific ProGuard rules here.
2
-# By default, the flags in this file are appended to flags specified
3
-# in /usr/local/Cellar/android-sdk/24.3.3/tools/proguard/proguard-android.txt
4
-# You can edit the include path and order by changing the proguardFiles
5
-# directive in build.gradle.
6
-#
7
-# For more details, see
8
-#   http://developer.android.com/guide/developing/tools/proguard.html
9
-
10
-# Add any project specific keep options here:
11
-
12
-# If your project uses WebView with JS, uncomment the following
13
-# and specify the fully qualified class name to the JavaScript interface
14
-# class:
15
-#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16
-#   public *;
17
-#}

+ 0
- 26
WebTest/android/app/src/main/AndroidManifest.xml Wyświetl plik

@@ -1,26 +0,0 @@
1
-<manifest xmlns:android="http://schemas.android.com/apk/res/android"
2
-    package="com.webtest">
3
-
4
-    <uses-permission android:name="android.permission.INTERNET" />
5
-    <uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/>
6
-
7
-    <application
8
-      android:name=".MainApplication"
9
-      android:label="@string/app_name"
10
-      android:icon="@mipmap/ic_launcher"
11
-      android:allowBackup="false"
12
-      android:theme="@style/AppTheme">
13
-      <activity
14
-        android:name=".MainActivity"
15
-        android:label="@string/app_name"
16
-        android:configChanges="keyboard|keyboardHidden|orientation|screenSize"
17
-        android:windowSoftInputMode="adjustResize">
18
-        <intent-filter>
19
-            <action android:name="android.intent.action.MAIN" />
20
-            <category android:name="android.intent.category.LAUNCHER" />
21
-        </intent-filter>
22
-      </activity>
23
-      <activity android:name="com.facebook.react.devsupport.DevSettingsActivity" />
24
-    </application>
25
-
26
-</manifest>

+ 0
- 15
WebTest/android/app/src/main/java/com/webtest/MainActivity.java Wyświetl plik

@@ -1,15 +0,0 @@
1
-package com.webtest;
2
-
3
-import com.facebook.react.ReactActivity;
4
-
5
-public class MainActivity extends ReactActivity {
6
-
7
-    /**
8
-     * Returns the name of the main component registered from JavaScript.
9
-     * This is used to schedule rendering of the component.
10
-     */
11
-    @Override
12
-    protected String getMainComponentName() {
13
-        return "WebTest";
14
-    }
15
-}

+ 0
- 47
WebTest/android/app/src/main/java/com/webtest/MainApplication.java Wyświetl plik

@@ -1,47 +0,0 @@
1
-package com.webtest;
2
-
3
-import android.app.Application;
4
-
5
-import com.facebook.react.ReactApplication;
6
-import com.reactnativecommunity.webview.RNCWebViewPackage;
7
-import com.facebook.react.ReactNativeHost;
8
-import com.facebook.react.ReactPackage;
9
-import com.facebook.react.shell.MainReactPackage;
10
-import com.facebook.soloader.SoLoader;
11
-
12
-import java.util.Arrays;
13
-import java.util.List;
14
-
15
-public class MainApplication extends Application implements ReactApplication {
16
-
17
-  private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {
18
-    @Override
19
-    public boolean getUseDeveloperSupport() {
20
-      return BuildConfig.DEBUG;
21
-    }
22
-
23
-    @Override
24
-    protected List<ReactPackage> getPackages() {
25
-      return Arrays.<ReactPackage>asList(
26
-          new MainReactPackage(),
27
-            new RNCWebViewPackage()
28
-      );
29
-    }
30
-
31
-    @Override
32
-    protected String getJSMainModuleName() {
33
-      return "index";
34
-    }
35
-  };
36
-
37
-  @Override
38
-  public ReactNativeHost getReactNativeHost() {
39
-    return mReactNativeHost;
40
-  }
41
-
42
-  @Override
43
-  public void onCreate() {
44
-    super.onCreate();
45
-    SoLoader.init(this, /* native exopackage */ false);
46
-  }
47
-}

BIN
WebTest/android/app/src/main/res/mipmap-hdpi/ic_launcher.png Wyświetl plik


BIN
WebTest/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png Wyświetl plik


BIN
WebTest/android/app/src/main/res/mipmap-mdpi/ic_launcher.png Wyświetl plik


BIN
WebTest/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png Wyświetl plik


BIN
WebTest/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png Wyświetl plik


BIN
WebTest/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png Wyświetl plik


BIN
WebTest/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png Wyświetl plik


BIN
WebTest/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png Wyświetl plik


BIN
WebTest/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png Wyświetl plik


BIN
WebTest/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png Wyświetl plik


+ 0
- 3
WebTest/android/app/src/main/res/values/strings.xml Wyświetl plik

@@ -1,3 +0,0 @@
1
-<resources>
2
-    <string name="app_name">WebTest</string>
3
-</resources>

+ 0
- 8
WebTest/android/app/src/main/res/values/styles.xml Wyświetl plik

@@ -1,8 +0,0 @@
1
-<resources>
2
-
3
-    <!-- Base application theme. -->
4
-    <style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
5
-        <!-- Customize your theme here. -->
6
-    </style>
7
-
8
-</resources>

+ 0
- 40
WebTest/android/build.gradle Wyświetl plik

@@ -1,40 +0,0 @@
1
-// Top-level build file where you can add configuration options common to all sub-projects/modules.
2
-
3
-buildscript {
4
-    repositories {
5
-        jcenter()
6
-        maven {
7
-            url 'https://maven.google.com/'
8
-            name 'Google'
9
-        }
10
-    }
11
-    dependencies {
12
-        classpath 'com.android.tools.build:gradle:2.3.3'
13
-
14
-        // NOTE: Do not place your application dependencies here; they belong
15
-        // in the individual module build.gradle files
16
-    }
17
-}
18
-
19
-allprojects {
20
-    repositories {
21
-        mavenLocal()
22
-        jcenter()
23
-        maven {
24
-            // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
25
-            url "$rootDir/../node_modules/react-native/android"
26
-        }
27
-        maven {
28
-            url 'https://maven.google.com/'
29
-            name 'Google'
30
-        }
31
-    }
32
-}
33
-
34
-ext {
35
-    buildToolsVersion = "26.0.3"
36
-    minSdkVersion = 16
37
-    compileSdkVersion = 26
38
-    targetSdkVersion = 26
39
-    supportLibVersion = "26.1.0"
40
-}

+ 0
- 20
WebTest/android/gradle.properties Wyświetl plik

@@ -1,20 +0,0 @@
1
-# Project-wide Gradle settings.
2
-
3
-# IDE (e.g. Android Studio) users:
4
-# Gradle settings configured through the IDE *will override*
5
-# any settings specified in this file.
6
-
7
-# For more details on how to configure your build environment visit
8
-# http://www.gradle.org/docs/current/userguide/build_environment.html
9
-
10
-# Specifies the JVM arguments used for the daemon process.
11
-# The setting is particularly useful for tweaking memory settings.
12
-# Default value: -Xmx10248m -XX:MaxPermSize=256m
13
-# org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
14
-
15
-# When configured, Gradle will run in incubating parallel mode.
16
-# This option should only be used with decoupled projects. More details, visit
17
-# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
18
-# org.gradle.parallel=true
19
-
20
-android.useDeprecatedNdk=true

BIN
WebTest/android/gradle/wrapper/gradle-wrapper.jar Wyświetl plik


+ 0
- 5
WebTest/android/gradle/wrapper/gradle-wrapper.properties Wyświetl plik

@@ -1,5 +0,0 @@
1
-distributionBase=GRADLE_USER_HOME
2
-distributionPath=wrapper/dists
3
-zipStoreBase=GRADLE_USER_HOME
4
-zipStorePath=wrapper/dists
5
-distributionUrl=https\://services.gradle.org/distributions/gradle-3.5.1-all.zip

+ 0
- 164
WebTest/android/gradlew Wyświetl plik

@@ -1,164 +0,0 @@
1
-#!/usr/bin/env bash
2
-
3
-##############################################################################
4
-##
5
-##  Gradle start up script for UN*X
6
-##
7
-##############################################################################
8
-
9
-# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
10
-DEFAULT_JVM_OPTS=""
11
-
12
-APP_NAME="Gradle"
13
-APP_BASE_NAME=`basename "$0"`
14
-
15
-# Use the maximum available, or set MAX_FD != -1 to use that value.
16
-MAX_FD="maximum"
17
-
18
-warn ( ) {
19
-    echo "$*"
20
-}
21
-
22
-die ( ) {
23
-    echo
24
-    echo "$*"
25
-    echo
26
-    exit 1
27
-}
28
-
29
-# OS specific support (must be 'true' or 'false').
30
-cygwin=false
31
-msys=false
32
-darwin=false
33
-case "`uname`" in
34
-  CYGWIN* )
35
-    cygwin=true
36
-    ;;
37
-  Darwin* )
38
-    darwin=true
39
-    ;;
40
-  MINGW* )
41
-    msys=true
42
-    ;;
43
-esac
44
-
45
-# For Cygwin, ensure paths are in UNIX format before anything is touched.
46
-if $cygwin ; then
47
-    [ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
48
-fi
49
-
50
-# Attempt to set APP_HOME
51
-# Resolve links: $0 may be a link
52
-PRG="$0"
53
-# Need this for relative symlinks.
54
-while [ -h "$PRG" ] ; do
55
-    ls=`ls -ld "$PRG"`
56
-    link=`expr "$ls" : '.*-> \(.*\)$'`
57
-    if expr "$link" : '/.*' > /dev/null; then
58
-        PRG="$link"
59
-    else
60
-        PRG=`dirname "$PRG"`"/$link"
61
-    fi
62
-done
63
-SAVED="`pwd`"
64
-cd "`dirname \"$PRG\"`/" >&-
65
-APP_HOME="`pwd -P`"
66
-cd "$SAVED" >&-
67
-
68
-CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
69
-
70
-# Determine the Java command to use to start the JVM.
71
-if [ -n "$JAVA_HOME" ] ; then
72
-    if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
73
-        # IBM's JDK on AIX uses strange locations for the executables
74
-        JAVACMD="$JAVA_HOME/jre/sh/java"
75
-    else
76
-        JAVACMD="$JAVA_HOME/bin/java"
77
-    fi
78
-    if [ ! -x "$JAVACMD" ] ; then
79
-        die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
80
-
81
-Please set the JAVA_HOME variable in your environment to match the
82
-location of your Java installation."
83
-    fi
84
-else
85
-    JAVACMD="java"
86
-    which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
87
-
88
-Please set the JAVA_HOME variable in your environment to match the
89
-location of your Java installation."
90
-fi
91
-
92
-# Increase the maximum file descriptors if we can.
93
-if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
94
-    MAX_FD_LIMIT=`ulimit -H -n`
95
-    if [ $? -eq 0 ] ; then
96
-        if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
97
-            MAX_FD="$MAX_FD_LIMIT"
98
-        fi
99
-        ulimit -n $MAX_FD
100
-        if [ $? -ne 0 ] ; then
101
-            warn "Could not set maximum file descriptor limit: $MAX_FD"
102
-        fi
103
-    else
104
-        warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
105
-    fi
106
-fi
107
-
108
-# For Darwin, add options to specify how the application appears in the dock
109
-if $darwin; then
110
-    GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
111
-fi
112
-
113
-# For Cygwin, switch paths to Windows format before running java
114
-if $cygwin ; then
115
-    APP_HOME=`cygpath --path --mixed "$APP_HOME"`
116
-    CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
117
-
118
-    # We build the pattern for arguments to be converted via cygpath
119
-    ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
120
-    SEP=""
121
-    for dir in $ROOTDIRSRAW ; do
122
-        ROOTDIRS="$ROOTDIRS$SEP$dir"
123
-        SEP="|"
124
-    done
125
-    OURCYGPATTERN="(^($ROOTDIRS))"
126
-    # Add a user-defined pattern to the cygpath arguments
127
-    if [ "$GRADLE_CYGPATTERN" != "" ] ; then
128
-        OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
129
-    fi
130
-    # Now convert the arguments - kludge to limit ourselves to /bin/sh
131
-    i=0
132
-    for arg in "$@" ; do
133
-        CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
134
-        CHECK2=`echo "$arg"|egrep -c "^-"`                                 ### Determine if an option
135
-
136
-        if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then                    ### Added a condition
137
-            eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
138
-        else
139
-            eval `echo args$i`="\"$arg\""
140
-        fi
141
-        i=$((i+1))
142
-    done
143
-    case $i in
144
-        (0) set -- ;;
145
-        (1) set -- "$args0" ;;
146
-        (2) set -- "$args0" "$args1" ;;
147
-        (3) set -- "$args0" "$args1" "$args2" ;;
148
-        (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
149
-        (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
150
-        (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
151
-        (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
152
-        (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
153
-        (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
154
-    esac
155
-fi
156
-
157
-# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
158
-function splitJvmOpts() {
159
-    JVM_OPTS=("$@")
160
-}
161
-eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
162
-JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
163
-
164
-exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"

+ 0
- 90
WebTest/android/gradlew.bat Wyświetl plik

@@ -1,90 +0,0 @@
1
-@if "%DEBUG%" == "" @echo off
2
-@rem ##########################################################################
3
-@rem
4
-@rem  Gradle startup script for Windows
5
-@rem
6
-@rem ##########################################################################
7
-
8
-@rem Set local scope for the variables with windows NT shell
9
-if "%OS%"=="Windows_NT" setlocal
10
-
11
-@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
12
-set DEFAULT_JVM_OPTS=
13
-
14
-set DIRNAME=%~dp0
15
-if "%DIRNAME%" == "" set DIRNAME=.
16
-set APP_BASE_NAME=%~n0
17
-set APP_HOME=%DIRNAME%
18
-
19
-@rem Find java.exe
20
-if defined JAVA_HOME goto findJavaFromJavaHome
21
-
22
-set JAVA_EXE=java.exe
23
-%JAVA_EXE% -version >NUL 2>&1
24
-if "%ERRORLEVEL%" == "0" goto init
25
-
26
-echo.
27
-echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
28
-echo.
29
-echo Please set the JAVA_HOME variable in your environment to match the
30
-echo location of your Java installation.
31
-
32
-goto fail
33
-
34
-:findJavaFromJavaHome
35
-set JAVA_HOME=%JAVA_HOME:"=%
36
-set JAVA_EXE=%JAVA_HOME%/bin/java.exe
37
-
38
-if exist "%JAVA_EXE%" goto init
39
-
40
-echo.
41
-echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
42
-echo.
43
-echo Please set the JAVA_HOME variable in your environment to match the
44
-echo location of your Java installation.
45
-
46
-goto fail
47
-
48
-:init
49
-@rem Get command-line arguments, handling Windowz variants
50
-
51
-if not "%OS%" == "Windows_NT" goto win9xME_args
52
-if "%@eval[2+2]" == "4" goto 4NT_args
53
-
54
-:win9xME_args
55
-@rem Slurp the command line arguments.
56
-set CMD_LINE_ARGS=
57
-set _SKIP=2
58
-
59
-:win9xME_args_slurp
60
-if "x%~1" == "x" goto execute
61
-
62
-set CMD_LINE_ARGS=%*
63
-goto execute
64
-
65
-:4NT_args
66
-@rem Get arguments from the 4NT Shell from JP Software
67
-set CMD_LINE_ARGS=%$
68
-
69
-:execute
70
-@rem Setup the command line
71
-
72
-set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
73
-
74
-@rem Execute Gradle
75
-"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
76
-
77
-:end
78
-@rem End local scope for the variables with windows NT shell
79
-if "%ERRORLEVEL%"=="0" goto mainEnd
80
-
81
-:fail
82
-rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
83
-rem the _cmd.exe /c_ return code!
84
-if  not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
85
-exit /b 1
86
-
87
-:mainEnd
88
-if "%OS%"=="Windows_NT" endlocal
89
-
90
-:omega

+ 0
- 8
WebTest/android/keystores/BUCK Wyświetl plik

@@ -1,8 +0,0 @@
1
-keystore(
2
-    name = "debug",
3
-    properties = "debug.keystore.properties",
4
-    store = "debug.keystore",
5
-    visibility = [
6
-        "PUBLIC",
7
-    ],
8
-)

+ 0
- 4
WebTest/android/keystores/debug.keystore.properties Wyświetl plik

@@ -1,4 +0,0 @@
1
-key.store=debug.keystore
2
-key.alias=androiddebugkey
3
-key.store.password=android
4
-key.alias.password=android

+ 0
- 5
WebTest/android/settings.gradle Wyświetl plik

@@ -1,5 +0,0 @@
1
-rootProject.name = 'WebTest'
2
-include ':react-native-webview'
3
-project(':react-native-webview').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-webview/android')
4
-
5
-include ':app'

+ 0
- 4
WebTest/app.json Wyświetl plik

@@ -1,4 +0,0 @@
1
-{
2
-  "name": "WebTest",
3
-  "displayName": "WebTest"
4
-}

+ 0
- 4
WebTest/e2e/config.json Wyświetl plik

@@ -1,4 +0,0 @@
1
-{
2
-    "setupTestFrameworkScriptFile": "./init.js",
3
-    "testEnvironment": "node"
4
-}

+ 0
- 19
WebTest/e2e/init.js Wyświetl plik

@@ -1,19 +0,0 @@
1
-const detox = require('detox');
2
-const config = require('../package.json').detox;
3
-const adapter = require('detox/runners/jest/adapter');
4
-
5
-jest.setTimeout(120000);
6
-jasmine.getEnv().addReporter(adapter);
7
-
8
-beforeAll(async () => {
9
-  await detox.init(config);
10
-});
11
-
12
-beforeEach(async () => {
13
-  await adapter.beforeEach();
14
-});
15
-
16
-afterAll(async () => {
17
-  await adapter.afterAll();
18
-  await detox.cleanup();
19
-});

+ 0
- 19
WebTest/e2e/webTest.spec.js Wyświetl plik

@@ -1,19 +0,0 @@
1
-describe('Example', () => {
2
-  beforeEach(async () => {
3
-    await device.reloadReactNative();
4
-  });
5
-
6
-  it('should have welcome screen', async () => {
7
-    await expect(element(by.id('welcome'))).toBeVisible();
8
-  });
9
-
10
-  // it('should show hello screen after tap', async () => {
11
-  //   await element(by.id('hello_button')).tap();
12
-  //   await expect(element(by.text('Hello!!!'))).toBeVisible();
13
-  // });
14
-
15
-  // it('should show world screen after tap', async () => {
16
-  //   await element(by.id('world_button')).tap();
17
-  //   await expect(element(by.text('World!!!'))).toBeVisible();
18
-  // });
19
-})

+ 0
- 7
WebTest/index.js Wyświetl plik

@@ -1,7 +0,0 @@
1
-/** @format */
2
-
3
-import {AppRegistry} from 'react-native';
4
-import App from './App';
5
-import {name as appName} from './app.json';
6
-
7
-AppRegistry.registerComponent(appName, () => App);

+ 0
- 54
WebTest/ios/WebTest-tvOS/Info.plist Wyświetl plik

@@ -1,54 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
-<plist version="1.0">
4
-<dict>
5
-	<key>CFBundleDevelopmentRegion</key>
6
-	<string>en</string>
7
-	<key>CFBundleExecutable</key>
8
-	<string>$(EXECUTABLE_NAME)</string>
9
-	<key>CFBundleIdentifier</key>
10
-	<string>org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)</string>
11
-	<key>CFBundleInfoDictionaryVersion</key>
12
-	<string>6.0</string>
13
-	<key>CFBundleName</key>
14
-	<string>$(PRODUCT_NAME)</string>
15
-	<key>CFBundlePackageType</key>
16
-	<string>APPL</string>
17
-	<key>CFBundleShortVersionString</key>
18
-	<string>1.0</string>
19
-	<key>CFBundleSignature</key>
20
-	<string>????</string>
21
-	<key>CFBundleVersion</key>
22
-	<string>1</string>
23
-	<key>LSRequiresIPhoneOS</key>
24
-	<true/>
25
-	<key>UILaunchStoryboardName</key>
26
-	<string>LaunchScreen</string>
27
-	<key>UIRequiredDeviceCapabilities</key>
28
-	<array>
29
-		<string>armv7</string>
30
-	</array>
31
-	<key>UISupportedInterfaceOrientations</key>
32
-	<array>
33
-		<string>UIInterfaceOrientationPortrait</string>
34
-		<string>UIInterfaceOrientationLandscapeLeft</string>
35
-		<string>UIInterfaceOrientationLandscapeRight</string>
36
-	</array>
37
-	<key>UIViewControllerBasedStatusBarAppearance</key>
38
-	<false/>
39
-	<key>NSLocationWhenInUseUsageDescription</key>
40
-	<string></string>
41
-	<key>NSAppTransportSecurity</key>
42
-	<!--See http://ste.vn/2015/06/10/configuring-app-transport-security-ios-9-osx-10-11/ -->
43
-	<dict>
44
-		<key>NSExceptionDomains</key>
45
-		<dict>
46
-			<key>localhost</key>
47
-			<dict>
48
-				<key>NSExceptionAllowsInsecureHTTPLoads</key>
49
-				<true/>
50
-			</dict>
51
-		</dict>
52
-	</dict>
53
-</dict>
54
-</plist>

+ 0
- 24
WebTest/ios/WebTest-tvOSTests/Info.plist Wyświetl plik

@@ -1,24 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
-<plist version="1.0">
4
-<dict>
5
-	<key>CFBundleDevelopmentRegion</key>
6
-	<string>en</string>
7
-	<key>CFBundleExecutable</key>
8
-	<string>$(EXECUTABLE_NAME)</string>
9
-	<key>CFBundleIdentifier</key>
10
-	<string>org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)</string>
11
-	<key>CFBundleInfoDictionaryVersion</key>
12
-	<string>6.0</string>
13
-	<key>CFBundleName</key>
14
-	<string>$(PRODUCT_NAME)</string>
15
-	<key>CFBundlePackageType</key>
16
-	<string>BNDL</string>
17
-	<key>CFBundleShortVersionString</key>
18
-	<string>1.0</string>
19
-	<key>CFBundleSignature</key>
20
-	<string>????</string>
21
-	<key>CFBundleVersion</key>
22
-	<string>1</string>
23
-</dict>
24
-</plist>

+ 0
- 1528
WebTest/ios/WebTest.xcodeproj/project.pbxproj
Plik diff jest za duży
Wyświetl plik


+ 0
- 129
WebTest/ios/WebTest.xcodeproj/xcshareddata/xcschemes/WebTest-tvOS.xcscheme Wyświetl plik

@@ -1,129 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-<Scheme
3
-   LastUpgradeVersion = "0820"
4
-   version = "1.3">
5
-   <BuildAction
6
-      parallelizeBuildables = "NO"
7
-      buildImplicitDependencies = "YES">
8
-      <BuildActionEntries>
9
-         <BuildActionEntry
10
-            buildForTesting = "YES"
11
-            buildForRunning = "YES"
12
-            buildForProfiling = "YES"
13
-            buildForArchiving = "YES"
14
-            buildForAnalyzing = "YES">
15
-            <BuildableReference
16
-               BuildableIdentifier = "primary"
17
-               BlueprintIdentifier = "2D2A28121D9B038B00D4039D"
18
-               BuildableName = "libReact.a"
19
-               BlueprintName = "React-tvOS"
20
-               ReferencedContainer = "container:../node_modules/react-native/React/React.xcodeproj">
21
-            </BuildableReference>
22
-         </BuildActionEntry>
23
-         <BuildActionEntry
24
-            buildForTesting = "YES"
25
-            buildForRunning = "YES"
26
-            buildForProfiling = "YES"
27
-            buildForArchiving = "YES"
28
-            buildForAnalyzing = "YES">
29
-            <BuildableReference
30
-               BuildableIdentifier = "primary"
31
-               BlueprintIdentifier = "2D02E47A1E0B4A5D006451C7"
32
-               BuildableName = "WebTest-tvOS.app"
33
-               BlueprintName = "WebTest-tvOS"
34
-               ReferencedContainer = "container:WebTest.xcodeproj">
35
-            </BuildableReference>
36
-         </BuildActionEntry>
37
-         <BuildActionEntry
38
-            buildForTesting = "YES"
39
-            buildForRunning = "YES"
40
-            buildForProfiling = "NO"
41
-            buildForArchiving = "NO"
42
-            buildForAnalyzing = "YES">
43
-            <BuildableReference
44
-               BuildableIdentifier = "primary"
45
-               BlueprintIdentifier = "2D02E48F1E0B4A5D006451C7"
46
-               BuildableName = "WebTest-tvOSTests.xctest"
47
-               BlueprintName = "WebTest-tvOSTests"
48
-               ReferencedContainer = "container:WebTest.xcodeproj">
49
-            </BuildableReference>
50
-         </BuildActionEntry>
51
-      </BuildActionEntries>
52
-   </BuildAction>
53
-   <TestAction
54
-      buildConfiguration = "Debug"
55
-      selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
56
-      selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
57
-      shouldUseLaunchSchemeArgsEnv = "YES">
58
-      <Testables>
59
-         <TestableReference
60
-            skipped = "NO">
61
-            <BuildableReference
62
-               BuildableIdentifier = "primary"
63
-               BlueprintIdentifier = "2D02E48F1E0B4A5D006451C7"
64
-               BuildableName = "WebTest-tvOSTests.xctest"
65
-               BlueprintName = "WebTest-tvOSTests"
66
-               ReferencedContainer = "container:WebTest.xcodeproj">
67
-            </BuildableReference>
68
-         </TestableReference>
69
-      </Testables>
70
-      <MacroExpansion>
71
-         <BuildableReference
72
-            BuildableIdentifier = "primary"
73
-            BlueprintIdentifier = "2D02E47A1E0B4A5D006451C7"
74
-            BuildableName = "WebTest-tvOS.app"
75
-            BlueprintName = "WebTest-tvOS"
76
-            ReferencedContainer = "container:WebTest.xcodeproj">
77
-         </BuildableReference>
78
-      </MacroExpansion>
79
-      <AdditionalOptions>
80
-      </AdditionalOptions>
81
-   </TestAction>
82
-   <LaunchAction
83
-      buildConfiguration = "Debug"
84
-      selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
85
-      selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
86
-      launchStyle = "0"
87
-      useCustomWorkingDirectory = "NO"
88
-      ignoresPersistentStateOnLaunch = "NO"
89
-      debugDocumentVersioning = "YES"
90
-      debugServiceExtension = "internal"
91
-      allowLocationSimulation = "YES">
92
-      <BuildableProductRunnable
93
-         runnableDebuggingMode = "0">
94
-         <BuildableReference
95
-            BuildableIdentifier = "primary"
96
-            BlueprintIdentifier = "2D02E47A1E0B4A5D006451C7"
97
-            BuildableName = "WebTest-tvOS.app"
98
-            BlueprintName = "WebTest-tvOS"
99
-            ReferencedContainer = "container:WebTest.xcodeproj">
100
-         </BuildableReference>
101
-      </BuildableProductRunnable>
102
-      <AdditionalOptions>
103
-      </AdditionalOptions>
104
-   </LaunchAction>
105
-   <ProfileAction
106
-      buildConfiguration = "Release"
107
-      shouldUseLaunchSchemeArgsEnv = "YES"
108
-      savedToolIdentifier = ""
109
-      useCustomWorkingDirectory = "NO"
110
-      debugDocumentVersioning = "YES">
111
-      <BuildableProductRunnable
112
-         runnableDebuggingMode = "0">
113
-         <BuildableReference
114
-            BuildableIdentifier = "primary"
115
-            BlueprintIdentifier = "2D02E47A1E0B4A5D006451C7"
116
-            BuildableName = "WebTest-tvOS.app"
117
-            BlueprintName = "WebTest-tvOS"
118
-            ReferencedContainer = "container:WebTest.xcodeproj">
119
-         </BuildableReference>
120
-      </BuildableProductRunnable>
121
-   </ProfileAction>
122
-   <AnalyzeAction
123
-      buildConfiguration = "Debug">
124
-   </AnalyzeAction>
125
-   <ArchiveAction
126
-      buildConfiguration = "Release"
127
-      revealArchiveInOrganizer = "YES">
128
-   </ArchiveAction>
129
-</Scheme>

+ 0
- 129
WebTest/ios/WebTest.xcodeproj/xcshareddata/xcschemes/WebTest.xcscheme Wyświetl plik

@@ -1,129 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-<Scheme
3
-   LastUpgradeVersion = "0620"
4
-   version = "1.3">
5
-   <BuildAction
6
-      parallelizeBuildables = "NO"
7
-      buildImplicitDependencies = "YES">
8
-      <BuildActionEntries>
9
-         <BuildActionEntry
10
-            buildForTesting = "YES"
11
-            buildForRunning = "YES"
12
-            buildForProfiling = "YES"
13
-            buildForArchiving = "YES"
14
-            buildForAnalyzing = "YES">
15
-            <BuildableReference
16
-               BuildableIdentifier = "primary"
17
-               BlueprintIdentifier = "83CBBA2D1A601D0E00E9B192"
18
-               BuildableName = "libReact.a"
19
-               BlueprintName = "React"
20
-               ReferencedContainer = "container:../node_modules/react-native/React/React.xcodeproj">
21
-            </BuildableReference>
22
-         </BuildActionEntry>
23
-         <BuildActionEntry
24
-            buildForTesting = "YES"
25
-            buildForRunning = "YES"
26
-            buildForProfiling = "YES"
27
-            buildForArchiving = "YES"
28
-            buildForAnalyzing = "YES">
29
-            <BuildableReference
30
-               BuildableIdentifier = "primary"
31
-               BlueprintIdentifier = "13B07F861A680F5B00A75B9A"
32
-               BuildableName = "WebTest.app"
33
-               BlueprintName = "WebTest"
34
-               ReferencedContainer = "container:WebTest.xcodeproj">
35
-            </BuildableReference>
36
-         </BuildActionEntry>
37
-         <BuildActionEntry
38
-            buildForTesting = "YES"
39
-            buildForRunning = "YES"
40
-            buildForProfiling = "NO"
41
-            buildForArchiving = "NO"
42
-            buildForAnalyzing = "YES">
43
-            <BuildableReference
44
-               BuildableIdentifier = "primary"
45
-               BlueprintIdentifier = "00E356ED1AD99517003FC87E"
46
-               BuildableName = "WebTestTests.xctest"
47
-               BlueprintName = "WebTestTests"
48
-               ReferencedContainer = "container:WebTest.xcodeproj">
49
-            </BuildableReference>
50
-         </BuildActionEntry>
51
-      </BuildActionEntries>
52
-   </BuildAction>
53
-   <TestAction
54
-      buildConfiguration = "Debug"
55
-      selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
56
-      selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
57
-      shouldUseLaunchSchemeArgsEnv = "YES">
58
-      <Testables>
59
-         <TestableReference
60
-            skipped = "NO">
61
-            <BuildableReference
62
-               BuildableIdentifier = "primary"
63
-               BlueprintIdentifier = "00E356ED1AD99517003FC87E"
64
-               BuildableName = "WebTestTests.xctest"
65
-               BlueprintName = "WebTestTests"
66
-               ReferencedContainer = "container:WebTest.xcodeproj">
67
-            </BuildableReference>
68
-         </TestableReference>
69
-      </Testables>
70
-      <MacroExpansion>
71
-         <BuildableReference
72
-            BuildableIdentifier = "primary"
73
-            BlueprintIdentifier = "13B07F861A680F5B00A75B9A"
74
-            BuildableName = "WebTest.app"
75
-            BlueprintName = "WebTest"
76
-            ReferencedContainer = "container:WebTest.xcodeproj">
77
-         </BuildableReference>
78
-      </MacroExpansion>
79
-      <AdditionalOptions>
80
-      </AdditionalOptions>
81
-   </TestAction>
82
-   <LaunchAction
83
-      buildConfiguration = "Debug"
84
-      selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
85
-      selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
86
-      launchStyle = "0"
87
-      useCustomWorkingDirectory = "NO"
88
-      ignoresPersistentStateOnLaunch = "NO"
89
-      debugDocumentVersioning = "YES"
90
-      debugServiceExtension = "internal"
91
-      allowLocationSimulation = "YES">
92
-      <BuildableProductRunnable
93
-         runnableDebuggingMode = "0">
94
-         <BuildableReference
95
-            BuildableIdentifier = "primary"
96
-            BlueprintIdentifier = "13B07F861A680F5B00A75B9A"
97
-            BuildableName = "WebTest.app"
98
-            BlueprintName = "WebTest"
99
-            ReferencedContainer = "container:WebTest.xcodeproj">
100
-         </BuildableReference>
101
-      </BuildableProductRunnable>
102
-      <AdditionalOptions>
103
-      </AdditionalOptions>
104
-   </LaunchAction>
105
-   <ProfileAction
106
-      buildConfiguration = "Release"
107
-      shouldUseLaunchSchemeArgsEnv = "YES"
108
-      savedToolIdentifier = ""
109
-      useCustomWorkingDirectory = "NO"
110
-      debugDocumentVersioning = "YES">
111
-      <BuildableProductRunnable
112
-         runnableDebuggingMode = "0">
113
-         <BuildableReference
114
-            BuildableIdentifier = "primary"
115
-            BlueprintIdentifier = "13B07F861A680F5B00A75B9A"
116
-            BuildableName = "WebTest.app"
117
-            BlueprintName = "WebTest"
118
-            ReferencedContainer = "container:WebTest.xcodeproj">
119
-         </BuildableReference>
120
-      </BuildableProductRunnable>
121
-   </ProfileAction>
122
-   <AnalyzeAction
123
-      buildConfiguration = "Debug">
124
-   </AnalyzeAction>
125
-   <ArchiveAction
126
-      buildConfiguration = "Release"
127
-      revealArchiveInOrganizer = "YES">
128
-   </ArchiveAction>
129
-</Scheme>

+ 0
- 14
WebTest/ios/WebTest/AppDelegate.h Wyświetl plik

@@ -1,14 +0,0 @@
1
-/**
2
- * Copyright (c) 2015-present, Facebook, Inc.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- */
7
-
8
-#import <UIKit/UIKit.h>
9
-
10
-@interface AppDelegate : UIResponder <UIApplicationDelegate>
11
-
12
-@property (nonatomic, strong) UIWindow *window;
13
-
14
-@end

+ 0
- 35
WebTest/ios/WebTest/AppDelegate.m Wyświetl plik

@@ -1,35 +0,0 @@
1
-/**
2
- * Copyright (c) 2015-present, Facebook, Inc.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- */
7
-
8
-#import "AppDelegate.h"
9
-
10
-#import <React/RCTBundleURLProvider.h>
11
-#import <React/RCTRootView.h>
12
-
13
-@implementation AppDelegate
14
-
15
-- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
16
-{
17
-  NSURL *jsCodeLocation;
18
-
19
-  jsCodeLocation = [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil];
20
-
21
-  RCTRootView *rootView = [[RCTRootView alloc] initWithBundleURL:jsCodeLocation
22
-                                                      moduleName:@"WebTest"
23
-                                               initialProperties:nil
24
-                                                   launchOptions:launchOptions];
25
-  rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1];
26
-
27
-  self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
28
-  UIViewController *rootViewController = [UIViewController new];
29
-  rootViewController.view = rootView;
30
-  self.window.rootViewController = rootViewController;
31
-  [self.window makeKeyAndVisible];
32
-  return YES;
33
-}
34
-
35
-@end

+ 0
- 42
WebTest/ios/WebTest/Base.lproj/LaunchScreen.xib Wyświetl plik

@@ -1,42 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
-<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="7702" systemVersion="14D136" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES">
3
-    <dependencies>
4
-        <deployment identifier="iOS"/>
5
-        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="7701"/>
6
-        <capability name="Constraints with non-1.0 multipliers" minToolsVersion="5.1"/>
7
-    </dependencies>
8
-    <objects>
9
-        <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
10
-        <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
11
-        <view contentMode="scaleToFill" id="iN0-l3-epB">
12
-            <rect key="frame" x="0.0" y="0.0" width="480" height="480"/>
13
-            <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
14
-            <subviews>
15
-                <label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Powered by React Native" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" minimumFontSize="9" translatesAutoresizingMaskIntoConstraints="NO" id="8ie-xW-0ye">
16
-                    <rect key="frame" x="20" y="439" width="441" height="21"/>
17
-                    <fontDescription key="fontDescription" type="system" pointSize="17"/>
18
-                    <color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
19
-                    <nil key="highlightedColor"/>
20
-                </label>
21
-                <label opaque="NO" clipsSubviews="YES" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="WebTest" textAlignment="center" lineBreakMode="middleTruncation" baselineAdjustment="alignBaselines" minimumFontSize="18" translatesAutoresizingMaskIntoConstraints="NO" id="kId-c2-rCX">
22
-                    <rect key="frame" x="20" y="140" width="441" height="43"/>
23
-                    <fontDescription key="fontDescription" type="boldSystem" pointSize="36"/>
24
-                    <color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
25
-                    <nil key="highlightedColor"/>
26
-                </label>
27
-            </subviews>
28
-            <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
29
-            <constraints>
30
-                <constraint firstItem="kId-c2-rCX" firstAttribute="centerY" secondItem="iN0-l3-epB" secondAttribute="bottom" multiplier="1/3" constant="1" id="5cJ-9S-tgC"/>
31
-                <constraint firstAttribute="centerX" secondItem="kId-c2-rCX" secondAttribute="centerX" id="Koa-jz-hwk"/>
32
-                <constraint firstAttribute="bottom" secondItem="8ie-xW-0ye" secondAttribute="bottom" constant="20" id="Kzo-t9-V3l"/>
33
-                <constraint firstItem="8ie-xW-0ye" firstAttribute="leading" secondItem="iN0-l3-epB" secondAttribute="leading" constant="20" symbolic="YES" id="MfP-vx-nX0"/>
34
-                <constraint firstAttribute="centerX" secondItem="8ie-xW-0ye" secondAttribute="centerX" id="ZEH-qu-HZ9"/>
35
-                <constraint firstItem="kId-c2-rCX" firstAttribute="leading" secondItem="iN0-l3-epB" secondAttribute="leading" constant="20" symbolic="YES" id="fvb-Df-36g"/>
36
-            </constraints>
37
-            <nil key="simulatedStatusBarMetrics"/>
38
-            <freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
39
-            <point key="canvasLocation" x="548" y="455"/>
40
-        </view>
41
-    </objects>
42
-</document>

+ 0
- 38
WebTest/ios/WebTest/Images.xcassets/AppIcon.appiconset/Contents.json Wyświetl plik

@@ -1,38 +0,0 @@
1
-{
2
-  "images" : [
3
-    {
4
-      "idiom" : "iphone",
5
-      "size" : "29x29",
6
-      "scale" : "2x"
7
-    },
8
-    {
9
-      "idiom" : "iphone",
10
-      "size" : "29x29",
11
-      "scale" : "3x"
12
-    },
13
-    {
14
-      "idiom" : "iphone",
15
-      "size" : "40x40",
16
-      "scale" : "2x"
17
-    },
18
-    {
19
-      "idiom" : "iphone",
20
-      "size" : "40x40",
21
-      "scale" : "3x"
22
-    },
23
-    {
24
-      "idiom" : "iphone",
25
-      "size" : "60x60",
26
-      "scale" : "2x"
27
-    },
28
-    {
29
-      "idiom" : "iphone",
30
-      "size" : "60x60",
31
-      "scale" : "3x"
32
-    }
33
-  ],
34
-  "info" : {
35
-    "version" : 1,
36
-    "author" : "xcode"
37
-  }
38
-}

+ 0
- 6
WebTest/ios/WebTest/Images.xcassets/Contents.json Wyświetl plik

@@ -1,6 +0,0 @@
1
-{
2
-  "info" : {
3
-    "version" : 1,
4
-    "author" : "xcode"
5
-  }
6
-}

+ 0
- 56
WebTest/ios/WebTest/Info.plist Wyświetl plik

@@ -1,56 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
-<plist version="1.0">
4
-<dict>
5
-	<key>CFBundleDevelopmentRegion</key>
6
-	<string>en</string>
7
-	<key>CFBundleDisplayName</key>
8
-	<string>WebTest</string>
9
-	<key>CFBundleExecutable</key>
10
-	<string>$(EXECUTABLE_NAME)</string>
11
-	<key>CFBundleIdentifier</key>
12
-	<string>org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)</string>
13
-	<key>CFBundleInfoDictionaryVersion</key>
14
-	<string>6.0</string>
15
-	<key>CFBundleName</key>
16
-	<string>$(PRODUCT_NAME)</string>
17
-	<key>CFBundlePackageType</key>
18
-	<string>APPL</string>
19
-	<key>CFBundleShortVersionString</key>
20
-	<string>1.0</string>
21
-	<key>CFBundleSignature</key>
22
-	<string>????</string>
23
-	<key>CFBundleVersion</key>
24
-	<string>1</string>
25
-	<key>LSRequiresIPhoneOS</key>
26
-	<true/>
27
-	<key>UILaunchStoryboardName</key>
28
-	<string>LaunchScreen</string>
29
-	<key>UIRequiredDeviceCapabilities</key>
30
-	<array>
31
-		<string>armv7</string>
32
-	</array>
33
-	<key>UISupportedInterfaceOrientations</key>
34
-	<array>
35
-		<string>UIInterfaceOrientationPortrait</string>
36
-		<string>UIInterfaceOrientationLandscapeLeft</string>
37
-		<string>UIInterfaceOrientationLandscapeRight</string>
38
-	</array>
39
-	<key>UIViewControllerBasedStatusBarAppearance</key>
40
-	<false/>
41
-	<key>NSLocationWhenInUseUsageDescription</key>
42
-	<string></string>
43
-	<key>NSAppTransportSecurity</key>
44
-	<!--See http://ste.vn/2015/06/10/configuring-app-transport-security-ios-9-osx-10-11/ -->
45
-	<dict>
46
-		<key>NSExceptionDomains</key>
47
-		<dict>
48
-			<key>localhost</key>
49
-			<dict>
50
-				<key>NSExceptionAllowsInsecureHTTPLoads</key>
51
-				<true/>
52
-			</dict>
53
-		</dict>
54
-	</dict>
55
-</dict>
56
-</plist>

+ 0
- 16
WebTest/ios/WebTest/main.m Wyświetl plik

@@ -1,16 +0,0 @@
1
-/**
2
- * Copyright (c) 2015-present, Facebook, Inc.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- */
7
-
8
-#import <UIKit/UIKit.h>
9
-
10
-#import "AppDelegate.h"
11
-
12
-int main(int argc, char * argv[]) {
13
-  @autoreleasepool {
14
-    return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
15
-  }
16
-}

+ 0
- 24
WebTest/ios/WebTestTests/Info.plist Wyświetl plik

@@ -1,24 +0,0 @@
1
-<?xml version="1.0" encoding="UTF-8"?>
2
-<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
3
-<plist version="1.0">
4
-<dict>
5
-	<key>CFBundleDevelopmentRegion</key>
6
-	<string>en</string>
7
-	<key>CFBundleExecutable</key>
8
-	<string>$(EXECUTABLE_NAME)</string>
9
-	<key>CFBundleIdentifier</key>
10
-	<string>org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)</string>
11
-	<key>CFBundleInfoDictionaryVersion</key>
12
-	<string>6.0</string>
13
-	<key>CFBundleName</key>
14
-	<string>$(PRODUCT_NAME)</string>
15
-	<key>CFBundlePackageType</key>
16
-	<string>BNDL</string>
17
-	<key>CFBundleShortVersionString</key>
18
-	<string>1.0</string>
19
-	<key>CFBundleSignature</key>
20
-	<string>????</string>
21
-	<key>CFBundleVersion</key>
22
-	<string>1</string>
23
-</dict>
24
-</plist>

+ 0
- 68
WebTest/ios/WebTestTests/WebTestTests.m Wyświetl plik

@@ -1,68 +0,0 @@
1
-/**
2
- * Copyright (c) 2015-present, Facebook, Inc.
3
- *
4
- * This source code is licensed under the MIT license found in the
5
- * LICENSE file in the root directory of this source tree.
6
- */
7
-
8
-#import <UIKit/UIKit.h>
9
-#import <XCTest/XCTest.h>
10
-
11
-#import <React/RCTLog.h>
12
-#import <React/RCTRootView.h>
13
-
14
-#define TIMEOUT_SECONDS 600
15
-#define TEXT_TO_LOOK_FOR @"Welcome to React Native!"
16
-
17
-@interface WebTestTests : XCTestCase
18
-
19
-@end
20
-
21
-@implementation WebTestTests
22
-
23
-- (BOOL)findSubviewInView:(UIView *)view matching:(BOOL(^)(UIView *view))test
24
-{
25
-  if (test(view)) {
26
-    return YES;
27
-  }
28
-  for (UIView *subview in [view subviews]) {
29
-    if ([self findSubviewInView:subview matching:test]) {
30
-      return YES;
31
-    }
32
-  }
33
-  return NO;
34
-}
35
-
36
-- (void)testRendersWelcomeScreen
37
-{
38
-  UIViewController *vc = [[[RCTSharedApplication() delegate] window] rootViewController];
39
-  NSDate *date = [NSDate dateWithTimeIntervalSinceNow:TIMEOUT_SECONDS];
40
-  BOOL foundElement = NO;
41
-
42
-  __block NSString *redboxError = nil;
43
-  RCTSetLogFunction(^(RCTLogLevel level, RCTLogSource source, NSString *fileName, NSNumber *lineNumber, NSString *message) {
44
-    if (level >= RCTLogLevelError) {
45
-      redboxError = message;
46
-    }
47
-  });
48
-
49
-  while ([date timeIntervalSinceNow] > 0 && !foundElement && !redboxError) {
50
-    [[NSRunLoop mainRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
51
-    [[NSRunLoop mainRunLoop] runMode:NSRunLoopCommonModes beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
52
-
53
-    foundElement = [self findSubviewInView:vc.view matching:^BOOL(UIView *view) {
54
-      if ([view.accessibilityLabel isEqualToString:TEXT_TO_LOOK_FOR]) {
55
-        return YES;
56
-      }
57
-      return NO;
58
-    }];
59
-  }
60
-
61
-  RCTSetLogFunction(RCTDefaultLogFunction);
62
-
63
-  XCTAssertNil(redboxError, @"RedBox error: %@", redboxError);
64
-  XCTAssertTrue(foundElement, @"Couldn't find element with text '%@' in %d seconds", TEXT_TO_LOOK_FOR, TIMEOUT_SECONDS);
65
-}
66
-
67
-
68
-@end

+ 0
- 37
WebTest/package.json Wyświetl plik

@@ -1,37 +0,0 @@
1
-{
2
-  "name": "WebTest",
3
-  "version": "0.0.1",
4
-  "private": true,
5
-  "scripts": {
6
-    "start": "node node_modules/react-native/local-cli/cli.js start",
7
-    "test": "jest"
8
-  },
9
-  "dependencies": {
10
-    "react": "16.4.1",
11
-    "react-native": "0.56.0",
12
-    "react-native-webview": "../"
13
-  },
14
-  "devDependencies": {
15
-    "@babel/core": "^7.0.0-beta",
16
-    "babel-core": "^7.0.0-beta",
17
-    "babel-jest": "23.4.2",
18
-    "babel-preset-react-native": "5.0.2",
19
-    "detox": "^8.1.4",
20
-    "jest": "23.5.0",
21
-    "react-test-renderer": "16.4.1"
22
-  },
23
-  "jest": {
24
-    "preset": "react-native"
25
-  },
26
-  "detox": {
27
-    "configurations": {
28
-      "ios.sim.debug": {
29
-        "binaryPath": "ios/build/Build/Products/Debug-iphonesimulator/WebTest.app",
30
-        "build": "xcodebuild -project ios/WebTest.xcodeproj -scheme WebTest -configuration Debug -sdk iphonesimulator -derivedDataPath ios/build",
31
-        "type": "ios.simulator",
32
-        "name": "iPhone 6"
33
-      }
34
-    },
35
-    "test-runner": "jest"
36
-  }
37
-}

+ 12
- 12
ios/RCTWKWebView.xcodeproj/project.pbxproj Wyświetl plik

@@ -24,7 +24,7 @@
24 24
 /* End PBXCopyFilesBuildPhase section */
25 25
 
26 26
 /* Begin PBXFileReference section */
27
-		134814201AA4EA6300B7C361 /* libRNCWebView.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libRNCWebView.a; sourceTree = BUILT_PRODUCTS_DIR; };
27
+		134814201AA4EA6300B7C361 /* libRCTWKWebView.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libRCTWKWebView.a; sourceTree = BUILT_PRODUCTS_DIR; };
28 28
 		E91B3462214383EF00F9801F /* RCTWKWebViewManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTWKWebViewManager.h; sourceTree = "<group>"; };
29 29
 		E91B3463214383EF00F9801F /* RCTWKWebView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = RCTWKWebView.h; sourceTree = "<group>"; };
30 30
 		E91B3464214383EF00F9801F /* RCTWKWebViewManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = RCTWKWebViewManager.m; sourceTree = "<group>"; };
@@ -45,7 +45,7 @@
45 45
 		134814211AA4EA7D00B7C361 /* Products */ = {
46 46
 			isa = PBXGroup;
47 47
 			children = (
48
-				134814201AA4EA6300B7C361 /* libRNCWebView.a */,
48
+				134814201AA4EA6300B7C361 /* libRCTWKWebView.a */,
49 49
 			);
50 50
 			name = Products;
51 51
 			sourceTree = "<group>";
@@ -64,9 +64,9 @@
64 64
 /* End PBXGroup section */
65 65
 
66 66
 /* Begin PBXNativeTarget section */
67
-		58B511DA1A9E6C8500147676 /* RNCWebView */ = {
67
+		58B511DA1A9E6C8500147676 /* RCTWKWebView */ = {
68 68
 			isa = PBXNativeTarget;
69
-			buildConfigurationList = 58B511EF1A9E6C8500147676 /* Build configuration list for PBXNativeTarget "RNCWebView" */;
69
+			buildConfigurationList = 58B511EF1A9E6C8500147676 /* Build configuration list for PBXNativeTarget "RCTWKWebView" */;
70 70
 			buildPhases = (
71 71
 				58B511D71A9E6C8500147676 /* Sources */,
72 72
 				58B511D81A9E6C8500147676 /* Frameworks */,
@@ -76,9 +76,9 @@
76 76
 			);
77 77
 			dependencies = (
78 78
 			);
79
-			name = RNCWebView;
79
+			name = RCTWKWebView;
80 80
 			productName = RCTDataManager;
81
-			productReference = 134814201AA4EA6300B7C361 /* libRNCWebView.a */;
81
+			productReference = 134814201AA4EA6300B7C361 /* libRCTWKWebView.a */;
82 82
 			productType = "com.apple.product-type.library.static";
83 83
 		};
84 84
 /* End PBXNativeTarget section */
@@ -95,7 +95,7 @@
95 95
 					};
96 96
 				};
97 97
 			};
98
-			buildConfigurationList = 58B511D61A9E6C8500147676 /* Build configuration list for PBXProject "RNCWebView" */;
98
+			buildConfigurationList = 58B511D61A9E6C8500147676 /* Build configuration list for PBXProject "RCTWKWebView" */;
99 99
 			compatibilityVersion = "Xcode 3.2";
100 100
 			developmentRegion = English;
101 101
 			hasScannedForEncodings = 0;
@@ -107,7 +107,7 @@
107 107
 			projectDirPath = "";
108 108
 			projectRoot = "";
109 109
 			targets = (
110
-				58B511DA1A9E6C8500147676 /* RNCWebView */,
110
+				58B511DA1A9E6C8500147676 /* RCTWKWebView */,
111 111
 			);
112 112
 		};
113 113
 /* End PBXProject section */
@@ -217,7 +217,7 @@
217 217
 				);
218 218
 				LIBRARY_SEARCH_PATHS = "$(inherited)";
219 219
 				OTHER_LDFLAGS = "-ObjC";
220
-				PRODUCT_NAME = RNCWebView;
220
+				PRODUCT_NAME = RCTWKWebView;
221 221
 				SKIP_INSTALL = YES;
222 222
 			};
223 223
 			name = Debug;
@@ -233,7 +233,7 @@
233 233
 				);
234 234
 				LIBRARY_SEARCH_PATHS = "$(inherited)";
235 235
 				OTHER_LDFLAGS = "-ObjC";
236
-				PRODUCT_NAME = RNCWebView;
236
+				PRODUCT_NAME = RCTWKWebView;
237 237
 				SKIP_INSTALL = YES;
238 238
 			};
239 239
 			name = Release;
@@ -241,7 +241,7 @@
241 241
 /* End XCBuildConfiguration section */
242 242
 
243 243
 /* Begin XCConfigurationList section */
244
-		58B511D61A9E6C8500147676 /* Build configuration list for PBXProject "RNCWebView" */ = {
244
+		58B511D61A9E6C8500147676 /* Build configuration list for PBXProject "RCTWKWebView" */ = {
245 245
 			isa = XCConfigurationList;
246 246
 			buildConfigurations = (
247 247
 				58B511ED1A9E6C8500147676 /* Debug */,
@@ -250,7 +250,7 @@
250 250
 			defaultConfigurationIsVisible = 0;
251 251
 			defaultConfigurationName = Release;
252 252
 		};
253
-		58B511EF1A9E6C8500147676 /* Build configuration list for PBXNativeTarget "RNCWebView" */ = {
253
+		58B511EF1A9E6C8500147676 /* Build configuration list for PBXNativeTarget "RCTWKWebView" */ = {
254 254
 			isa = XCConfigurationList;
255 255
 			buildConfigurations = (
256 256
 				58B511F01A9E6C8500147676 /* Debug */,