Undefined symbols for architecture arm64 - JSClassCreate

I found a similar problem when I compile a release version to target "Test". (Didn't encounter when compile to a debug version)

Undefined symbols for architecture arm64:
  "_RCTSetLogFunction", referenced from:
      -[citieswegoTests testRendersWelcomeScreen] in citieswegoTests.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

I try to remove options "arm64 & arm7" from the "valid Architectures" in target "Tests" and the problem is resolved. Hope this help.

  1. Change the "select a project or target" e.g Tests.
  2. remove "arm64 & arm7" from "valid Architectures"
  3. compile your project with release mode.
  SDKs:
    iOS SDK:
      Platforms: iOS 12.4, macOS 10.14, tvOS 12.4, watchOS 5.3
  IDEs:
    Xcode: 10.3/10G8 - /usr/bin/xcodebuild
  npmPackages:
    react: 16.8.6 => 16.8.6 
    react-native: 0.60.5 => 0.60.5 
  npmGlobalPackages:
    react-native-cli: 2.0.1
    react-native-git-upgrade: 0.2.7
    react-native-macos-cli: 2.0.1

Make sure JavaScriptCore.framework is added to Link Binary With Libraries