mirror of
https://github.com/status-im/realm-js.git
synced 2025-02-20 02:18:26 +00:00
Merge branch 'al-android-example' of https://github.com/realm/realm-js into al-android-example
This commit is contained in:
commit
40c02b5cbd
@ -30,7 +30,7 @@ function start_packager()
|
|||||||
else
|
else
|
||||||
echo "Waiting for packager."
|
echo "Waiting for packager."
|
||||||
sleep 2
|
sleep 2
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -38,7 +38,7 @@ function start_packager()
|
|||||||
pkill node || true
|
pkill node || true
|
||||||
|
|
||||||
if [ "$TARGET" = "realmjs" ]; then
|
if [ "$TARGET" = "realmjs" ]; then
|
||||||
xcodebuild -scheme RealmJS -configuration "$CONFIGURATION" -sdk iphonesimulator $DESTINATION build test
|
xcodebuild -scheme RealmJS -configuration "$CONFIGURATION" -sdk iphonesimulator $DESTINATION build test
|
||||||
elif [ "$TARGET" = "react-tests" ]; then
|
elif [ "$TARGET" = "react-tests" ]; then
|
||||||
pushd tests/react-test-app
|
pushd tests/react-test-app
|
||||||
|
|
||||||
@ -52,7 +52,7 @@ elif [ "$TARGET" = "react-tests" ]; then
|
|||||||
npm update react-native
|
npm update react-native
|
||||||
start_packager
|
start_packager
|
||||||
popd
|
popd
|
||||||
|
|
||||||
xcodebuild -scheme RealmReact -configuration "$CONFIGURATION" -sdk iphonesimulator $DESTINATION build test
|
xcodebuild -scheme RealmReact -configuration "$CONFIGURATION" -sdk iphonesimulator $DESTINATION build test
|
||||||
elif [ "$TARGET" = "react-example" ]; then
|
elif [ "$TARGET" = "react-example" ]; then
|
||||||
pushd examples/ReactExample
|
pushd examples/ReactExample
|
||||||
@ -66,6 +66,16 @@ elif [ "$TARGET" = "react-example" ]; then
|
|||||||
xcodebuild -scheme ReactExample -configuration "$CONFIGURATION" -sdk iphonesimulator build $DESTINATION
|
xcodebuild -scheme ReactExample -configuration "$CONFIGURATION" -sdk iphonesimulator build $DESTINATION
|
||||||
popd
|
popd
|
||||||
elif [ "$TARGET" = "react-tests-android" ]; then
|
elif [ "$TARGET" = "react-tests-android" ]; then
|
||||||
|
# update sdk tool
|
||||||
|
expect -c '
|
||||||
|
set timeout -1;
|
||||||
|
spawn /opt/android-sdk-linux/tools/android update sdk -u -a -t "build-tools-23.0.1";
|
||||||
|
expect {
|
||||||
|
"Do you accept the license" { exp_send "y\r" ; exp_continue }
|
||||||
|
eof
|
||||||
|
}
|
||||||
|
'
|
||||||
|
|
||||||
pushd react-native/android
|
pushd react-native/android
|
||||||
./gradlew installarchives
|
./gradlew installarchives
|
||||||
popd
|
popd
|
||||||
@ -80,7 +90,7 @@ elif [ "$TARGET" = "react-tests-android" ]; then
|
|||||||
start_packager
|
start_packager
|
||||||
|
|
||||||
sh run-android.sh
|
sh run-android.sh
|
||||||
|
|
||||||
LOGCAT_OUT="logcat_out.txt"
|
LOGCAT_OUT="logcat_out.txt"
|
||||||
rm -f $LOGCAT_OUT
|
rm -f $LOGCAT_OUT
|
||||||
|
|
||||||
@ -94,8 +104,8 @@ elif [ "$TARGET" = "react-tests-android" ]; then
|
|||||||
else
|
else
|
||||||
echo "Waiting for tests."
|
echo "Waiting for tests."
|
||||||
sleep 2
|
sleep 2
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
|
||||||
adb pull /data/data/com.demo/files/tests.xml . || true
|
adb pull /data/data/com.demo/files/tests.xml . || true
|
||||||
else
|
else
|
||||||
@ -107,4 +117,3 @@ pkill -P $$ || true
|
|||||||
pkill node || true
|
pkill node || true
|
||||||
rm -f $PACKAGER_OUT
|
rm -f $PACKAGER_OUT
|
||||||
rm -f $LOGCAT_OUT
|
rm -f $LOGCAT_OUT
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user