expo-dev-menu 6.0.0 → 6.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -10,6 +10,10 @@
|
|
|
10
10
|
|
|
11
11
|
### 💡 Others
|
|
12
12
|
|
|
13
|
+
## 6.0.1 — 2024-10-22
|
|
14
|
+
|
|
15
|
+
_This version does not introduce any user-facing changes._
|
|
16
|
+
|
|
13
17
|
## 6.0.0 — 2024-10-22
|
|
14
18
|
|
|
15
19
|
### 🛠 Breaking changes
|
|
@@ -31,6 +35,7 @@
|
|
|
31
35
|
- Removed `expo_patch_react_imports!` and align more stardard react-native project layout. ([#31700](https://github.com/expo/expo/pull/31700) by [@kudo](https://github.com/kudo))
|
|
32
36
|
- Removed deprecated code for SDK 49. ([#31740](https://github.com/expo/expo/pull/31740) by [@kudo](https://github.com/kudo))
|
|
33
37
|
- Remove unused `semver` dependency. ([#32063](https://github.com/expo/expo/pull/32063) by [@kitten](https://github.com/kitten))
|
|
38
|
+
- Fixed broken unit tests since React Native 0.76 bump. ([#32210](https://github.com/expo/expo/pull/32210) by [@kudo](https://github.com/kudo))
|
|
34
39
|
|
|
35
40
|
## 5.0.21 - 2024-08-23
|
|
36
41
|
|
package/android/build.gradle
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
apply plugin: 'com.android.library'
|
|
2
2
|
|
|
3
3
|
group = 'host.exp.exponent'
|
|
4
|
-
version = '6.0.
|
|
4
|
+
version = '6.0.1'
|
|
5
5
|
|
|
6
6
|
def expoModulesCorePlugin = new File(project(":expo-modules-core").projectDir.absolutePath, "ExpoModulesCorePlugin.gradle")
|
|
7
7
|
apply from: expoModulesCorePlugin
|
|
@@ -20,7 +20,7 @@ android {
|
|
|
20
20
|
namespace "expo.modules.devmenu"
|
|
21
21
|
defaultConfig {
|
|
22
22
|
versionCode 10
|
|
23
|
-
versionName '6.0.
|
|
23
|
+
versionName '6.0.1'
|
|
24
24
|
}
|
|
25
25
|
|
|
26
26
|
buildTypes {
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
// Copyright 2015-present 650 Industries. All rights reserved.
|
|
2
|
+
|
|
3
|
+
import Quick
|
|
4
|
+
import Nimble
|
|
5
|
+
import React
|
|
6
|
+
|
|
7
|
+
@testable import EXDevMenu
|
|
8
|
+
|
|
9
|
+
internal class MockBridgeDelegate: NSObject, RCTBridgeDelegate {
|
|
10
|
+
var loadSourceCalled = false
|
|
11
|
+
|
|
12
|
+
func sourceURL(for bridge: RCTBridge) -> URL? {
|
|
13
|
+
return URL(string: "http://localhost:8081/index.bundle")
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
func loadSource(for bridge: RCTBridge, onProgress: @escaping RCTSourceLoadProgressBlock, onComplete loadCallback: @escaping RCTSourceLoadBlock) {
|
|
17
|
+
loadSourceCalled = true
|
|
18
|
+
|
|
19
|
+
// Executes callback nil for both error and source looks strange but that's the only way we can bypass the lock
|
|
20
|
+
loadCallback(nil, nil)
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
internal func waitBridgeReady(bridgeDelegate: MockBridgeDelegate) {
|
|
25
|
+
expect(bridgeDelegate.loadSourceCalled).toEventually(beTrue())
|
|
26
|
+
}
|
|
@@ -8,10 +8,6 @@ class DevMenuAppInstanceTest: QuickSpec {
|
|
|
8
8
|
class MockedBridge: RCTBridge {
|
|
9
9
|
var enqueueJSCallWasCalled = false
|
|
10
10
|
|
|
11
|
-
override func invalidate() {
|
|
12
|
-
// NOOP
|
|
13
|
-
}
|
|
14
|
-
|
|
15
11
|
override func enqueueJSCall(_ moduleDotMethod: String!, args: [Any]!) {
|
|
16
12
|
enqueueJSCallWasCalled = true
|
|
17
13
|
|
|
@@ -22,7 +18,9 @@ class DevMenuAppInstanceTest: QuickSpec {
|
|
|
22
18
|
|
|
23
19
|
override class func spec() {
|
|
24
20
|
it("checks if `sendCloseEvent` sends correct event") {
|
|
25
|
-
let
|
|
21
|
+
let bridgeDelegate = MockBridgeDelegate()
|
|
22
|
+
let mockedBridge = MockedBridge(delegate: bridgeDelegate, launchOptions: nil)!
|
|
23
|
+
waitBridgeReady(bridgeDelegate: bridgeDelegate)
|
|
26
24
|
let appInstance = DevMenuAppInstance(
|
|
27
25
|
manager: DevMenuManager.shared,
|
|
28
26
|
bridge: mockedBridge
|
|
@@ -34,7 +32,9 @@ class DevMenuAppInstanceTest: QuickSpec {
|
|
|
34
32
|
}
|
|
35
33
|
|
|
36
34
|
it("checks if js bundle was found") {
|
|
37
|
-
let
|
|
35
|
+
let bridgeDelegate = MockBridgeDelegate()
|
|
36
|
+
let mockedBridge = MockedBridge(delegate: bridgeDelegate, launchOptions: nil)!
|
|
37
|
+
waitBridgeReady(bridgeDelegate: bridgeDelegate)
|
|
38
38
|
let appInstance = DevMenuAppInstance(
|
|
39
39
|
manager: DevMenuManager.shared,
|
|
40
40
|
bridge: mockedBridge
|
|
@@ -46,7 +46,9 @@ class DevMenuAppInstanceTest: QuickSpec {
|
|
|
46
46
|
}
|
|
47
47
|
|
|
48
48
|
it("checks if extra modules was exported") {
|
|
49
|
-
let
|
|
49
|
+
let bridgeDelegate = MockBridgeDelegate()
|
|
50
|
+
let mockedBridge = MockedBridge(delegate: bridgeDelegate, launchOptions: nil)!
|
|
51
|
+
waitBridgeReady(bridgeDelegate: bridgeDelegate)
|
|
50
52
|
let appInstance = DevMenuAppInstance(
|
|
51
53
|
manager: DevMenuManager.shared,
|
|
52
54
|
bridge: mockedBridge
|
|
@@ -11,13 +11,17 @@ class DevMenuRCTBridgeTest: QuickSpec {
|
|
|
11
11
|
|
|
12
12
|
override class func spec() {
|
|
13
13
|
it("should be connected with DevMenuRCTCxxBridge") {
|
|
14
|
-
let
|
|
14
|
+
let bridgeDelegate = MockBridgeDelegate()
|
|
15
|
+
let bridge = DevMenuRCTBridge(delegate: bridgeDelegate, launchOptions: nil)!
|
|
16
|
+
waitBridgeReady(bridgeDelegate: bridgeDelegate)
|
|
15
17
|
|
|
16
18
|
expect(bridge.bridgeClass()).to(be(DevMenuRCTCxxBridge.self))
|
|
17
19
|
}
|
|
18
20
|
|
|
19
21
|
it("should be able to filter non essential modules") {
|
|
20
|
-
let
|
|
22
|
+
let bridgeDelegate = MockBridgeDelegate()
|
|
23
|
+
let cxxBridge = DevMenuRCTBridge(delegate: bridgeDelegate, launchOptions: nil)!.batched as! DevMenuRCTCxxBridge
|
|
24
|
+
waitBridgeReady(bridgeDelegate: bridgeDelegate)
|
|
21
25
|
|
|
22
26
|
let filteredModules = cxxBridge.filterModuleList([RCTAllowModule.self, NotAllowModule.self])
|
|
23
27
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "expo-dev-menu",
|
|
3
|
-
"version": "6.0.
|
|
3
|
+
"version": "6.0.1",
|
|
4
4
|
"description": "Expo/React Native module with the developer menu.",
|
|
5
5
|
"main": "build/DevMenu.js",
|
|
6
6
|
"types": "build/DevMenu.d.ts",
|
|
@@ -56,7 +56,7 @@
|
|
|
56
56
|
"@testing-library/react-native": "^12.5.1",
|
|
57
57
|
"babel-plugin-module-resolver": "^5.0.0",
|
|
58
58
|
"babel-preset-expo": "~12.0.0-preview.0",
|
|
59
|
-
"expo-dev-client-components": "2.0.
|
|
59
|
+
"expo-dev-client-components": "2.0.1",
|
|
60
60
|
"expo-module-scripts": "^4.0.0",
|
|
61
61
|
"fuse.js": "^6.4.6",
|
|
62
62
|
"graphql": "^15.3.0",
|
|
@@ -69,5 +69,5 @@
|
|
|
69
69
|
"peerDependencies": {
|
|
70
70
|
"expo": "*"
|
|
71
71
|
},
|
|
72
|
-
"gitHead": "
|
|
72
|
+
"gitHead": "f7adac0a6b82ab484a8254a68c3808ba6f2afde5"
|
|
73
73
|
}
|