Skip to content
This repository has been archived by the owner on Jan 23, 2023. It is now read-only.

collating test_result bundles in Xcode 11 crashes #145

Closed
4 tasks done
jineshqa opened this issue Sep 25, 2019 · 75 comments
Closed
4 tasks done

collating test_result bundles in Xcode 11 crashes #145

jineshqa opened this issue Sep 25, 2019 · 75 comments

Comments

@jineshqa
Copy link
Contributor

jineshqa commented Sep 25, 2019

New Issue Checklist

  • Updated fastlane-plugin-test_center to the latest version
  • I read the README.md
  • I reviewed the example(s) for the action(s) I am using
  • I have removed any sensitive data such as passwords, authentication tokens, or anything else I do not want to world to see

Issue Description

I am trying to run tests using multi_scan, at the end of parallel test run collate actions fail. Please see the output for more details.

Complete output when running fastlane, including the stack trace and command used
You can ⌘ + double-click on links to open them directly in your browser.
[11:22:21]: Deleting iPhone Xs 13 Clone 1 TestCenter::Helper::MultiScanManager::SimulatorHelper<70323043884920>
[11:22:27]: Deleting iPhone Xs 13 Clone 2 TestCenter::Helper::MultiScanManager::SimulatorHelper<70323043884920>
/Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/actions/collate_test_result_bundles.rb:97:in `collate_infoplist': [!] undefined method `zip' for nil:NilClass (NoMethodError)
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/actions/collate_test_result_bundles.rb:25:in `block in collate_bundles'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/actions/collate_test_result_bundles.rb:23:in `foreach'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/actions/collate_test_result_bundles.rb:23:in `collate_bundles'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/actions/collate_test_result_bundles.rb:14:in `block in run'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/actions/collate_test_result_bundles.rb:13:in `each'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/actions/collate_test_result_bundles.rb:13:in `run'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/helper/multi_scan_manager/report_collator.rb:127:in `collate_test_result_bundles'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/helper/multi_scan_manager/report_collator.rb:24:in `collate'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/helper/multi_scan_manager/runner.rb:204:in `collate_batched_reports_for_testable'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/helper/multi_scan_manager/runner.rb:165:in `block in collate_batched_reports'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/helper/multi_scan_manager/runner.rb:164:in `each'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/helper/multi_scan_manager/runner.rb:164:in `collate_batched_reports'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/helper/multi_scan_manager/runner.rb:146:in `run_test_batches'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/helper/multi_scan_manager/runner.rb:53:in `run'
	from /Users/jdoshi/.gems/gems/fastlane-plugin-test_center-3.8.4/lib/fastlane/plugin/test_center/actions/multi_scan.rb:23:in `run'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/runner.rb:256:in `block (2 levels) in execute_action'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/actions/actions_helper.rb:50:in `execute_action'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/runner.rb:235:in `block in execute_action'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/runner.rb:227:in `chdir'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/runner.rb:227:in `execute_action'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/runner.rb:157:in `trigger_action_by_name'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/fast_file.rb:154:in `method_missing'
	from Fastfile:597:in `block (2 levels) in parsing_binding'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/lane.rb:33:in `call'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/runner.rb:49:in `block in execute'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/runner.rb:45:in `chdir'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/runner.rb:45:in `execute'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/lane_manager.rb:56:in `cruise_lane'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/command_line_handler.rb:36:in `handle'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/commands_generator.rb:108:in `block (2 levels) in run'
	from /Library/Ruby/Gems/2.3.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:178:in `call'
	from /Library/Ruby/Gems/2.3.0/gems/commander-fastlane-4.4.6/lib/commander/command.rb:153:in `run'
	from /Library/Ruby/Gems/2.3.0/gems/commander-fastlane-4.4.6/lib/commander/runner.rb:476:in `run_active_command'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane_core/lib/fastlane_core/ui/fastlane_runner.rb:76:in `run!'
	from /Library/Ruby/Gems/2.3.0/gems/commander-fastlane-4.4.6/lib/commander/delegates.rb:15:in `run!'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/commands_generator.rb:349:in `run'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/commands_generator.rb:41:in `start'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/fastlane/lib/fastlane/cli_tools_distributor.rb:119:in `take_off'
	from /Users/jdoshi/.gems/gems/fastlane-2.131.0/bin/fastlane:23:in `'
	from /Users/jdoshi/.gems/bin/fastlane:22:in `load'
	from /Users/jdoshi/.gems/bin/fastlane:22:in `'

Environment

✅ fastlane environment ✅

Stack

Key Value
OS 10.14.5
Ruby 2.3.7
Bundler? false
Git git version 2.19.0
Installation Source ~/.gems/bin/fastlane
Host Mac OS X 10.14.5 (18F132)
Ruby Lib Dir /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib
OpenSSL Version LibreSSL 2.6.5
Is contained false
Is homebrew false
Is installed via Fabric.app false
Xcode Path /Applications/Xcode11.app/Contents/Developer/
Xcode Version 11.0

System Locale

Variable Value
LANG en_US.UTF-8
LC_ALL
LANGUAGE

fastlane gems

Gem Version Update-Status
fastlane 2.131.0 ✅ Up-To-Date

Loaded fastlane plugins:

Plugin Version Update-Status
fastlane-plugin-test_center 3.8.4 ✅ Up-To-Date
Loaded gems
Gem Version
did_you_mean 1.0.0
slack-notifier 2.3.2
rouge 2.0.7
xcpretty 0.3.0
terminal-notifier 2.0.0
terminal-table 1.8.0
multipart-post 2.0.0
word_wrap 1.0.0
public_suffix 2.0.5
babosa 1.0.2
colored 1.2
highline 1.7.10
commander-fastlane 4.4.6
http-cookie 1.0.3
faraday-cookie_jar 0.0.6
gh_inspector 1.1.3
mini_magick 4.9.5
multi_xml 0.6.0
security 0.1.3
xcpretty-travis-formatter 1.0.0
naturally 2.2.0
simctl 1.6.5
jwt 2.1.0
uber 0.1.0
declarative 0.0.10
declarative-option 0.1.0
representable 3.0.4
retriable 3.1.2
mime-types 3.2.2
httpclient 2.8.3
google-api-client 0.23.9
tty-cursor 0.7.0
tty-spinner 0.9.1
tty-screen 0.7.0
faraday 0.15.4
json 2.2.0
io-console 0.4.5
excon 0.66.0
rubyzip 1.2.3
CFPropertyList 3.0.1
libxml-ruby 2.9.0
plist 3.5.0
atomos 0.1.3
colored2 3.1.2
nanaimo 0.2.6
xcodeproj 1.12.0
claide 1.0.3
google-cloud-env 1.2.1
google-cloud-core 1.3.1
digest-crc 0.4.1
google-cloud-storage 1.16.0
memoist 0.16.0
multi_json 1.13.1
googleauth 0.6.7
unf 0.1.4
domain_name 0.5.20190701
faraday_middleware 0.13.1
signet 0.11.0
fastimage 2.1.5
bundler 2.0.2
unicode-display_width 1.6.0
addressable 2.6.0
os 1.0.1
psych 2.1.0.1
mime-types-data 3.2019.0331
xctest_list 1.1.8
colorize 0.8.1
fastlane-plugin-test_center 3.8.4

generated on: 2019-09-25

@lyndsey-ferguson
Copy link
Owner

This works fine for Xcode 10?

@jineshqa
Copy link
Contributor Author

Yes it does. Also, take a look at this as well.

fastlane/fastlane#15138

@lyndsey-ferguson
Copy link
Owner

lyndsey-ferguson commented Sep 25, 2019

@jineshqa do you have a theory that they are somehow related? This issue that you created seems to indicate that there is a problem collating test result bundles. The issue that you reference fastlane/fastlane#15138 indicates that there is a crash after uploading to testflight.

@lyndsey-ferguson
Copy link
Owner

I saw that you commented in the issue. According to the stack trace of the crash, these are not related issues.

@lyndsey-ferguson
Copy link
Owner

lyndsey-ferguson commented Sep 25, 2019

As this fails in both Xcode 10 and Xcode 11, this is probably not related to the versions. I haven't changed anything in the collation of test result bundles of v3.8.4 vs. v.3.8.x.

You must have something in your project that is catching an edge case that I have not encountered before. I need either the test result bundles to see why the collation fails, or a sample project that you can submit freely that exhibits the problem.

🙏

@jineshqa
Copy link
Contributor Author

Hey Lyndsey,

This does not fail on xcode 10.

Thanks,
Jinesh

@lyndsey-ferguson
Copy link
Owner

lyndsey-ferguson commented Sep 26, 2019

Okay. Can you provide the test result bundles?

@lyndsey-ferguson
Copy link
Owner

Oh, and another question, if you remove the request to create test_result bundles, does it still crash?

@jineshqa
Copy link
Contributor Author

I am not sure I can try.

@jineshqa
Copy link
Contributor Author

Also, will get you sample project.

jineshqa pushed a commit to jineshqa/collate_errors that referenced this issue Sep 27, 2019
@jineshqa
Copy link
Contributor Author

I am not sure I can try.

This is didn't help.

@jineshqa
Copy link
Contributor Author

Also, will get you sample project.

Sample project is located here

Test output is attached.
test_outout.zip

@jineshqa
Copy link
Contributor Author

@lyndsey-ferguson is above info good enough.

@lyndsey-ferguson
Copy link
Owner

@jineshqa yes, I was able to fix the crash. I have a PR open.

Can you modify your Pluginfile per my instructions below, run bundle install, and then run your fastlane again (with the --verbose flag)?

Pluginfile:

gem 'fastlane-plugin-test_center', :git => "https://github.com/lyndsey-ferguson/fastlane-plugin-test_center.git", :branch => "issue-145-crash-when-collating-test-bundles"

If there are still problems, please let me know and attach the console output as a text file to this issue (makes it easier for me to review). If it works, please let me know.

@lyndsey-ferguson
Copy link
Owner

However, I do not believe that collation now works. The test summaries no longer exist and the tests failures and passes are no longer listed.

@lyndsey-ferguson
Copy link
Owner

It looks like there is a new format:
fastlane-community/trainer#32

@lyndsey-ferguson
Copy link
Owner

Ok, this looks like a lot of work.

@lyndsey-ferguson
Copy link
Owner

I'm going to change this issue to a Feature Request to support Xcode 11 format.

@lyndsey-ferguson lyndsey-ferguson changed the title Error at the end of test runs on Xcode 11 iOS 13 Feature Request: Support the new Xcode 11 test result format Oct 1, 2019
@lyndsey-ferguson lyndsey-ferguson changed the title Feature Request: Support the new Xcode 11 test result format collating test_result bundles in Xcode 11 crashes Oct 1, 2019
@lyndsey-ferguson
Copy link
Owner

Actually, I can issue a fix for now until test_result bundles can be collated with the new format.

@lyndsey-ferguson
Copy link
Owner

@jineshqa try running the branch I suggested above with multi_scan. It will use version 2 of the test result bundle path

@jineshqa
Copy link
Contributor Author

jineshqa commented Oct 1, 2019

This should have everything you need.

console-verbose.log
console.log

@lyndsey-ferguson
Copy link
Owner

Please try again.

Delete your Gemfile.lock file, make sure that you have modified your Pluginfile per my instructions below, run bundle install, and then run your fastlane again (with the --verbose flag).

Pluginfile:

gem 'fastlane-plugin-test_center', :git => "https://github.com/lyndsey-ferguson/fastlane-plugin-test_center.git", :branch => "issue-145-crash-when-collating-test-bundles"

If there are still problems, please let me know and attach the complete console output as a text file to this issue (makes it easier for me to review). If it works, please let me know.

@lyndsey-ferguson
Copy link
Owner

Is the ENABLE_TESTABILITY on for that test target?

@lyndsey-ferguson
Copy link
Owner

Does that xctest file exist?

@jineshqa
Copy link
Contributor Author

Enable_testability is on and xctest file does exist. However I get this message at the beginning of the run. Do you think this has anything to do with missing tests?
Ignoring byebug-11.0.1 because its extensions are not built. Try: gem pristine byebug --version 11.0.1

@jineshqa
Copy link
Contributor Author

Any idea what would cause this?

[15:40:09]: $ set -o pipefail && env NSUnbufferedIO=YES xcodebuild -scheme collate\ errors -project ./collate_errors.xcodeproj -destination 'platform=iOS Simulator,id=D67DE434-EABF-46AA-84BB-522E7061C854' -derivedDataPath '/Users/jdoshi/Documents/Jinesh/ios/code/collate_errors/DerivedData/collate_errors' -resultBundlePath './fastlane/test_output/collate errors.test_result' -enableCodeCoverage YES build-for-testing | tee '/Users/jdoshi/Documents/Jinesh/ios/code/collate_errors/fastlane/test_output/collate_errors-collate errors.log' | xcpretty  --report junit --output '/Users/jdoshi/Documents/Jinesh/ios/code/collate_errors/fastlane/test_output/report.junit' --report html --output '/Users/jdoshi/Documents/Jinesh/ios/code/collate_errors/fastlane/test_output/report.html' --report junit --output '/var/folders/_v/385bsl711hj8mg07gcv518y80000gn/T/junit_report20191016-58813-r4hkz5'
[15:40:09]: ▸ Loading...
[15:40:11]: ▸ Test build Succeeded
+--------------------+---+
|      Test Results      |
+--------------------+---+
| Number of tests    | 0 |
| Number of failures | 0 |
+--------------------+---+

nm: invalid option -- U
Usage: nm [option(s)] [file(s)]
 List symbols in [file(s)] (a.out by default).
 The options are:
  -a, --debug-syms       Display debugger-only symbols
  -A, --print-file-name  Print name of the input file before every symbol
  -B                     Same as --format=bsd
  -C, --demangle[=STYLE] Decode low-level symbol names into user-level names
                          The STYLE, if specified, can be `auto' (the default),
                          `gnu', `lucid', `arm', `hp', `edg', `gnu-v3', `java'
                          or `gnat'
      --no-demangle      Do not demangle low-level symbol names
      --recurse-limit    Enable a demangling recursion limit.  This is the default.
      --no-recurse-limit Disable a demangling recursion limit.
  -D, --dynamic          Display dynamic symbols instead of normal symbols
      --defined-only     Display only defined symbols
  -e                     (ignored)
  -f, --format=FORMAT    Use the output format FORMAT.  FORMAT can be `bsd',
                           `sysv' or `posix'.  The default is `bsd'
  -g, --extern-only      Display only external symbols
  -l, --line-numbers     Use debugging information to find a filename and
                           line number for each symbol
  -n, --numeric-sort     Sort symbols numerically by address
  -o                     Same as -A
  -p, --no-sort          Do not sort the symbols
  -P, --portability      Same as --format=posix
  -r, --reverse-sort     Reverse the sense of the sort
      --plugin NAME      Load the specified plugin
  -S, --print-size       Print size of defined symbols
  -s, --print-armap      Include index for symbols from archive members
      --size-sort        Sort symbols by size
      --special-syms     Include special symbols in the output
      --synthetic        Display synthetic symbols as well
  -t, --radix=RADIX      Use RADIX for printing symbol values
      --target=BFDNAME   Specify the target object format as BFDNAME
  -u, --undefined-only   Display only undefined symbols
      --with-symbol-versions  Display version strings after symbol names
  -X 32_64               (ignored)
  @FILE                  Read options from FILE
  -h, --help             Display this information
  -V, --version          Display this program's version number

nm: supported targets: mach-o-x86-64 elf32-bigaarch64 elf32-littleaarch64 elf64-bigaarch64 elf64-bigaarch64-cloudabi elf64-littleaarch64 elf64-littleaarch64-cloudabi mach-o-arm64 ecoff-littlealpha elf64-alpha elf64-alpha-freebsd vms-alpha vms-libtxt elf32-am33lin elf32-bigarc elf32-littlearc elf32-bigarm elf32-littlearm elf32-bigarm-fdpic elf32-littlearm-fdpic elf32-bigarm-symbian elf32-littlearm-symbian elf32-bigarm-vxworks elf32-littlearm-vxworks mach-o-arm pe-arm-big pe-arm-little pe-arm-wince-big pe-arm-wince-little pei-arm-big pei-arm-little pei-arm-wince-big pei-arm-wince-little elf32-avr elf32-bfin elf32-bfinfdpic elf32-cr16 elf32-cr16c a.out-cris elf32-cris elf32-us-cris elf32-crx elf32-csky-big elf32-csky-little elf32-d10v elf32-d30v elf32-dlx elf32-big elf32-little elf64-big elf64-little elf32-epiphany elf32-fr30 elf32-frv elf32-frvfdpic elf32-h8300 elf32-h8300-linux elf32-hppa elf32-hppa-linux elf32-hppa-netbsd elf64-hppa elf64-hppa-linux som a.out-i386 a.out-i386-bsd a.out-i386-lynx coff-i386 coff-go32 coff-go32-exe coff-i386-lynx elf32-i386 elf32-i386-freebsd elf32-i386-nacl elf32-i386-sol2 elf32-i386-vxworks mach-o-i386 msdos pe-i386 pei-i386 elf32-iamcu elf32-ia64-hpux-big elf64-ia64-big elf64-ia64-little elf64-ia64-hpux-big elf64-ia64-vms pei-ia64 elf32-ip2k elf32-iq2000 elf64-k1om elf64-k1om-freebsd elf64-l1om elf64-l1om-freebsd elf32-lm32 elf32-m32c elf32-m32r elf32-m32rle elf32-m32r-linux elf32-m32rle-linux elf32-m68hc11 elf32-m68hc12 elf32-m68k elf32-s12z mach-o-be mach-o-le mach-o-fat elf32-mcore-big elf32-mcore-little pe-mcore-big pe-mcore-little pei-mcore-big pei-mcore-little elf32-mep elf32-metag elf32-microblaze ecoff-bigmips ecoff-littlemips ecoff-biglittlemips elf32-bigmips elf32-littlemips elf32-nbigmips elf32-nlittlemips elf32-ntradbigmips elf32-ntradlittlemips elf32-ntradbigmips-freebsd elf32-ntradlittlemips-freebsd elf32-tradbigmips elf32-tradlittlemips elf32-tradbigmips-freebsd elf32-tradlittlemips-freebsd elf32-bigmips-vxworks elf32-littlemips-vxworks elf64-bigmips elf64-littlemips elf64-tradbigmips elf64-tradlittlemips elf64-tradbigmips-freebsd elf64-tradlittlemips-freebsd elf64-mmix mmo elf32-mn10200 elf32-mn10300 elf32-bigmoxie elf32-littlemoxie elf32-msp430 elf32-msp430 elf32-mt elf32-nds32be elf32-nds32le elf32-nds32be-linux elf32-nds32le-linux elf64-nfp elf32-bignios2 elf32-littlenios2 a.out-pc532-mach a.out-ns32k-netbsd elf32-or1k a.out-pdp11 pef pef-xlib elf32-pj elf32-pjl plugin ppcboot elf32-powerpc elf32-powerpcle elf32-powerpc-freebsd elf32-powerpc-vxworks elf64-powerpc elf64-powerpcle elf64-powerpc-freebsd pe-powerpc pe-powerpcle pei-powerpc pei-powerpcle elf32-pru elf32-littleriscv elf64-littleriscv elf32-rl78 aixcoff64-rs6000 aix5coff64-rs6000 aixcoff-rs6000 elf32-rx-be elf32-rx-be-ns elf32-rx-le elf32-s390 elf64-s390 elf32-bigscore elf32-littlescore coff-sh coff-shl coff-sh-small coff-shl-small elf32-sh elf32-shl elf32-shbig-fdpic elf32-sh-fdpic elf32-sh-linux elf32-shbig-linux elf32-sh-nbsd elf32-shl-nbsd elf32-sh-vxworks elf32-shl-vxworks pe-shl pei-shl elf32-sparc elf32-sparc-sol2 elf32-sparc-vxworks elf64-sparc elf64-sparc-freebsd elf64-sparc-sol2 elf32-spu sym a.out-tic30 coff-tic30 coff0-beh-c54x coff0-c54x coff1-beh-c54x coff1-c54x coff2-beh-c54x coff2-c54x elf32-tic6x-be elf32-tic6x-le coff-tic80 elf32-tilegx-be elf32-tilegx-le elf64-tilegx-be elf64-tilegx-le elf32-tilepro elf32-ft32 elf32-v850-rh850 elf32-v850 a.out-vax1k-netbsd a.out-vax-netbsd elf32-vax elf32-visium wasm elf32-wasm32 coff-x86-64 elf32-x86-64 elf32-x86-64-nacl elf64-x86-64 elf64-x86-64-cloudabi elf64-x86-64-freebsd elf64-x86-64-nacl elf64-x86-64-sol2 pe-x86-64 pe-bigobj-x86-64 pei-x86-64 elf32-xc16x elf32-xgate elf32-xstormy16 elf32-xtensa-be elf32-xtensa-le coff-z80 coff-z8k srec symbolsrec verilog tekhex binary ihex
nm: invalid option -- i
Usage: nm [option(s)] [file(s)]
 List symbols in [file(s)] (a.out by default).
 The options are:
  -a, --debug-syms       Display debugger-only symbols
  -A, --print-file-name  Print name of the input file before every symbol
  -B                     Same as --format=bsd
  -C, --demangle[=STYLE] Decode low-level symbol names into user-level names
                          The STYLE, if specified, can be `auto' (the default),
                          `gnu', `lucid', `arm', `hp', `edg', `gnu-v3', `java'
                          or `gnat'
      --no-demangle      Do not demangle low-level symbol names
      --recurse-limit    Enable a demangling recursion limit.  This is the default.
      --no-recurse-limit Disable a demangling recursion limit.
  -D, --dynamic          Display dynamic symbols instead of normal symbols
      --defined-only     Display only defined symbols
  -e                     (ignored)
  -f, --format=FORMAT    Use the output format FORMAT.  FORMAT can be `bsd',
                           `sysv' or `posix'.  The default is `bsd'
  -g, --extern-only      Display only external symbols
  -l, --line-numbers     Use debugging information to find a filename and
                           line number for each symbol
  -n, --numeric-sort     Sort symbols numerically by address
  -o                     Same as -A
  -p, --no-sort          Do not sort the symbols
  -P, --portability      Same as --format=posix
  -r, --reverse-sort     Reverse the sense of the sort
      --plugin NAME      Load the specified plugin
  -S, --print-size       Print size of defined symbols
  -s, --print-armap      Include index for symbols from archive members
      --size-sort        Sort symbols by size
      --special-syms     Include special symbols in the output
      --synthetic        Display synthetic symbols as well
  -t, --radix=RADIX      Use RADIX for printing symbol values
      --target=BFDNAME   Specify the target object format as BFDNAME
  -u, --undefined-only   Display only undefined symbols
      --with-symbol-versions  Display version strings after symbol names
  -X 32_64               (ignored)
  @FILE                  Read options from FILE
  -h, --help             Display this information
  -V, --version          Display this program's version number

nm: supported targets: mach-o-x86-64 elf32-bigaarch64 elf32-littleaarch64 elf64-bigaarch64 elf64-bigaarch64-cloudabi elf64-littleaarch64 elf64-littleaarch64-cloudabi mach-o-arm64 ecoff-littlealpha elf64-alpha elf64-alpha-freebsd vms-alpha vms-libtxt elf32-am33lin elf32-bigarc elf32-littlearc elf32-bigarm elf32-littlearm elf32-bigarm-fdpic elf32-littlearm-fdpic elf32-bigarm-symbian elf32-littlearm-symbian elf32-bigarm-vxworks elf32-littlearm-vxworks mach-o-arm pe-arm-big pe-arm-little pe-arm-wince-big pe-arm-wince-little pei-arm-big pei-arm-little pei-arm-wince-big pei-arm-wince-little elf32-avr elf32-bfin elf32-bfinfdpic elf32-cr16 elf32-cr16c a.out-cris elf32-cris elf32-us-cris elf32-crx elf32-csky-big elf32-csky-little elf32-d10v elf32-d30v elf32-dlx elf32-big elf32-little elf64-big elf64-little elf32-epiphany elf32-fr30 elf32-frv elf32-frvfdpic elf32-h8300 elf32-h8300-linux elf32-hppa elf32-hppa-linux elf32-hppa-netbsd elf64-hppa elf64-hppa-linux som a.out-i386 a.out-i386-bsd a.out-i386-lynx coff-i386 coff-go32 coff-go32-exe coff-i386-lynx elf32-i386 elf32-i386-freebsd elf32-i386-nacl elf32-i386-sol2 elf32-i386-vxworks mach-o-i386 msdos pe-i386 pei-i386 elf32-iamcu elf32-ia64-hpux-big elf64-ia64-big elf64-ia64-little elf64-ia64-hpux-big elf64-ia64-vms pei-ia64 elf32-ip2k elf32-iq2000 elf64-k1om elf64-k1om-freebsd elf64-l1om elf64-l1om-freebsd elf32-lm32 elf32-m32c elf32-m32r elf32-m32rle elf32-m32r-linux elf32-m32rle-linux elf32-m68hc11 elf32-m68hc12 elf32-m68k elf32-s12z mach-o-be mach-o-le mach-o-fat elf32-mcore-big elf32-mcore-little pe-mcore-big pe-mcore-little pei-mcore-big pei-mcore-little elf32-mep elf32-metag elf32-microblaze ecoff-bigmips ecoff-littlemips ecoff-biglittlemips elf32-bigmips elf32-littlemips elf32-nbigmips elf32-nlittlemips elf32-ntradbigmips elf32-ntradlittlemips elf32-ntradbigmips-freebsd elf32-ntradlittlemips-freebsd elf32-tradbigmips elf32-tradlittlemips elf32-tradbigmips-freebsd elf32-tradlittlemips-freebsd elf32-bigmips-vxworks elf32-littlemips-vxworks elf64-bigmips elf64-littlemips elf64-tradbigmips elf64-tradlittlemips elf64-tradbigmips-freebsd elf64-tradlittlemips-freebsd elf64-mmix mmo elf32-mn10200 elf32-mn10300 elf32-bigmoxie elf32-littlemoxie elf32-msp430 elf32-msp430 elf32-mt elf32-nds32be elf32-nds32le elf32-nds32be-linux elf32-nds32le-linux elf64-nfp elf32-bignios2 elf32-littlenios2 a.out-pc532-mach a.out-ns32k-netbsd elf32-or1k a.out-pdp11 pef pef-xlib elf32-pj elf32-pjl plugin ppcboot elf32-powerpc elf32-powerpcle elf32-powerpc-freebsd elf32-powerpc-vxworks elf64-powerpc elf64-powerpcle elf64-powerpc-freebsd pe-powerpc pe-powerpcle pei-powerpc pei-powerpcle elf32-pru elf32-littleriscv elf64-littleriscv elf32-rl78 aixcoff64-rs6000 aix5coff64-rs6000 aixcoff-rs6000 elf32-rx-be elf32-rx-be-ns elf32-rx-le elf32-s390 elf64-s390 elf32-bigscore elf32-littlescore coff-sh coff-shl coff-sh-small coff-shl-small elf32-sh elf32-shl elf32-shbig-fdpic elf32-sh-fdpic elf32-sh-linux elf32-shbig-linux elf32-sh-nbsd elf32-shl-nbsd elf32-sh-vxworks elf32-shl-vxworks pe-shl pei-shl elf32-sparc elf32-sparc-sol2 elf32-sparc-vxworks elf64-sparc elf64-sparc-freebsd elf64-sparc-sol2 elf32-spu sym a.out-tic30 coff-tic30 coff0-beh-c54x coff0-c54x coff1-beh-c54x coff1-c54x coff2-beh-c54x coff2-c54x elf32-tic6x-be elf32-tic6x-le coff-tic80 elf32-tilegx-be elf32-tilegx-le elf64-tilegx-be elf64-tilegx-le elf32-tilepro elf32-ft32 elf32-v850-rh850 elf32-v850 a.out-vax1k-netbsd a.out-vax-netbsd elf32-vax elf32-visium wasm elf32-wasm32 coff-x86-64 elf32-x86-64 elf32-x86-64-nacl elf64-x86-64 elf64-x86-64-cloudabi elf64-x86-64-freebsd elf64-x86-64-nacl elf64-x86-64-sol2 pe-x86-64 pe-bigobj-x86-64 pei-x86-64 elf32-xc16x elf32-xgate elf32-xstormy16 elf32-xtensa-be elf32-xtensa-le coff-z80 coff-z8k srec symbolsrec verilog tekhex binary ihex
nm: invalid option -- U
Usage: nm [option(s)] [file(s)]
 List symbols in [file(s)] (a.out by default).
 The options are:
  -a, --debug-syms       Display debugger-only symbols
  -A, --print-file-name  Print name of the input file before every symbol
  -B                     Same as --format=bsd
  -C, --demangle[=STYLE] Decode low-level symbol names into user-level names
                          The STYLE, if specified, can be `auto' (the default),
                          `gnu', `lucid', `arm', `hp', `edg', `gnu-v3', `java'
                          or `gnat'
      --no-demangle      Do not demangle low-level symbol names
      --recurse-limit    Enable a demangling recursion limit.  This is the default.
      --no-recurse-limit Disable a demangling recursion limit.
  -D, --dynamic          Display dynamic symbols instead of normal symbols
      --defined-only     Display only defined symbols
  -e                     (ignored)
  -f, --format=FORMAT    Use the output format FORMAT.  FORMAT can be `bsd',
                           `sysv' or `posix'.  The default is `bsd'
  -g, --extern-only      Display only external symbols
  -l, --line-numbers     Use debugging information to find a filename and
                           line number for each symbol
  -n, --numeric-sort     Sort symbols numerically by address
  -o                     Same as -A
  -p, --no-sort          Do not sort the symbols
  -P, --portability      Same as --format=posix
  -r, --reverse-sort     Reverse the sense of the sort
      --plugin NAME      Load the specified plugin
  -S, --print-size       Print size of defined symbols
  -s, --print-armap      Include index for symbols from archive members
      --size-sort        Sort symbols by size
      --special-syms     Include special symbols in the output
      --synthetic        Display synthetic symbols as well
  -t, --radix=RADIX      Use RADIX for printing symbol values
      --target=BFDNAME   Specify the target object format as BFDNAME
  -u, --undefined-only   Display only undefined symbols
      --with-symbol-versions  Display version strings after symbol names
  -X 32_64               (ignored)
  @FILE                  Read options from FILE
  -h, --help             Display this information
  -V, --version          Display this program's version number

nm: supported targets: mach-o-x86-64 elf32-bigaarch64 elf32-littleaarch64 elf64-bigaarch64 elf64-bigaarch64-cloudabi elf64-littleaarch64 elf64-littleaarch64-cloudabi mach-o-arm64 ecoff-littlealpha elf64-alpha elf64-alpha-freebsd vms-alpha vms-libtxt elf32-am33lin elf32-bigarc elf32-littlearc elf32-bigarm elf32-littlearm elf32-bigarm-fdpic elf32-littlearm-fdpic elf32-bigarm-symbian elf32-littlearm-symbian elf32-bigarm-vxworks elf32-littlearm-vxworks mach-o-arm pe-arm-big pe-arm-little pe-arm-wince-big pe-arm-wince-little pei-arm-big pei-arm-little pei-arm-wince-big pei-arm-wince-little elf32-avr elf32-bfin elf32-bfinfdpic elf32-cr16 elf32-cr16c a.out-cris elf32-cris elf32-us-cris elf32-crx elf32-csky-big elf32-csky-little elf32-d10v elf32-d30v elf32-dlx elf32-big elf32-little elf64-big elf64-little elf32-epiphany elf32-fr30 elf32-frv elf32-frvfdpic elf32-h8300 elf32-h8300-linux elf32-hppa elf32-hppa-linux elf32-hppa-netbsd elf64-hppa elf64-hppa-linux som a.out-i386 a.out-i386-bsd a.out-i386-lynx coff-i386 coff-go32 coff-go32-exe coff-i386-lynx elf32-i386 elf32-i386-freebsd elf32-i386-nacl elf32-i386-sol2 elf32-i386-vxworks mach-o-i386 msdos pe-i386 pei-i386 elf32-iamcu elf32-ia64-hpux-big elf64-ia64-big elf64-ia64-little elf64-ia64-hpux-big elf64-ia64-vms pei-ia64 elf32-ip2k elf32-iq2000 elf64-k1om elf64-k1om-freebsd elf64-l1om elf64-l1om-freebsd elf32-lm32 elf32-m32c elf32-m32r elf32-m32rle elf32-m32r-linux elf32-m32rle-linux elf32-m68hc11 elf32-m68hc12 elf32-m68k elf32-s12z mach-o-be mach-o-le mach-o-fat elf32-mcore-big elf32-mcore-little pe-mcore-big pe-mcore-little pei-mcore-big pei-mcore-little elf32-mep elf32-metag elf32-microblaze ecoff-bigmips ecoff-littlemips ecoff-biglittlemips elf32-bigmips elf32-littlemips elf32-nbigmips elf32-nlittlemips elf32-ntradbigmips elf32-ntradlittlemips elf32-ntradbigmips-freebsd elf32-ntradlittlemips-freebsd elf32-tradbigmips elf32-tradlittlemips elf32-tradbigmips-freebsd elf32-tradlittlemips-freebsd elf32-bigmips-vxworks elf32-littlemips-vxworks elf64-bigmips elf64-littlemips elf64-tradbigmips elf64-tradlittlemips elf64-tradbigmips-freebsd elf64-tradlittlemips-freebsd elf64-mmix mmo elf32-mn10200 elf32-mn10300 elf32-bigmoxie elf32-littlemoxie elf32-msp430 elf32-msp430 elf32-mt elf32-nds32be elf32-nds32le elf32-nds32be-linux elf32-nds32le-linux elf64-nfp elf32-bignios2 elf32-littlenios2 a.out-pc532-mach a.out-ns32k-netbsd elf32-or1k a.out-pdp11 pef pef-xlib elf32-pj elf32-pjl plugin ppcboot elf32-powerpc elf32-powerpcle elf32-powerpc-freebsd elf32-powerpc-vxworks elf64-powerpc elf64-powerpcle elf64-powerpc-freebsd pe-powerpc pe-powerpcle pei-powerpc pei-powerpcle elf32-pru elf32-littleriscv elf64-littleriscv elf32-rl78 aixcoff64-rs6000 aix5coff64-rs6000 aixcoff-rs6000 elf32-rx-be elf32-rx-be-ns elf32-rx-le elf32-s390 elf64-s390 elf32-bigscore elf32-littlescore coff-sh coff-shl coff-sh-small coff-shl-small elf32-sh elf32-shl elf32-shbig-fdpic elf32-sh-fdpic elf32-sh-linux elf32-shbig-linux elf32-sh-nbsd elf32-shl-nbsd elf32-sh-vxworks elf32-shl-vxworks pe-shl pei-shl elf32-sparc elf32-sparc-sol2 elf32-sparc-vxworks elf64-sparc elf64-sparc-freebsd elf64-sparc-sol2 elf32-spu sym a.out-tic30 coff-tic30 coff0-beh-c54x coff0-c54x coff1-beh-c54x coff1-c54x coff2-beh-c54x coff2-c54x elf32-tic6x-be elf32-tic6x-le coff-tic80 elf32-tilegx-be elf32-tilegx-le elf64-tilegx-be elf64-tilegx-le elf32-tilepro elf32-ft32 elf32-v850-rh850 elf32-v850 a.out-vax1k-netbsd a.out-vax-netbsd elf32-vax elf32-visium wasm elf32-wasm32 coff-x86-64 elf32-x86-64 elf32-x86-64-nacl elf64-x86-64 elf64-x86-64-cloudabi elf64-x86-64-freebsd elf64-x86-64-nacl elf64-x86-64-sol2 pe-x86-64 pe-bigobj-x86-64 pei-x86-64 elf32-xc16x elf32-xgate elf32-xstormy16 elf32-xtensa-be elf32-xtensa-le coff-z80 coff-z8k srec symbolsrec verilog tekhex binary ihex
[15:40:11]: No tests found in '/Users/jdoshi/Documents/Jinesh/ios/code/collate_errors/DerivedData/collate_errors/Build/Products/Debug-iphonesimulator/collate_errorsUITests-Runner.app/PlugIns/collate_errorsUITests.xctest'!
[15:40:11]: Is the Build Setting, `ENABLE_TESTABILITY` enabled for the test target collate_errorsUITests?

+-------------------+------+
|    multi_scan results    |
+-------------------+------+
| result            | true |
| total_tests       | 0    |
| passing_testcount | 0    |
| failed_testcount  | 0    |
| failed_tests      | []   |
| total_retry_count | 0    |
| report_files      | []   |
+-------------------+------+


+------+----------------------+-------------+
|             fastlane summary              |
+------+----------------------+-------------+
| Step | Action               | Time (in s) |
+------+----------------------+-------------+
| 1    | default_platform     | 0           |
| 2    | rm -rf ./test_output | 0           |
| 3    | multi_scan           | 16          |
+------+----------------------+-------------+

[15:40:23]: fastlane.tools finished successfully 🎉
[15:40:23]: Deleting iPhone 11 Clone 1 TestCenter::Helper::MultiScanManager::SimulatorHelper<70164688052480>
[15:40:30]: Deleting iPhone 11 Clone 2 TestCenter::Helper::MultiScanManager::SimulatorHelper<70164688052480>

@lyndsey-ferguson
Copy link
Owner

Any idea what would cause this?

[15:40:09]: $ set -o pipefail && env NSUnbufferedIO=YES xcodebuild -scheme collate\ errors -project ./collate_errors.xcodeproj -destination 'platform=iOS Simulator,id=D67DE434-EABF-46AA-84BB-522E7061C854' -derivedDataPath '/Users/jdoshi/Documents/Jinesh/ios/code/collate_errors/DerivedData/collate_errors' -resultBundlePath './fastlane/test_output/collate errors.test_result' -enableCodeCoverage YES build-for-testing | tee '/Users/jdoshi/Documents/Jinesh/ios/code/collate_errors/fastlane/test_output/collate_errors-collate errors.log' | xcpretty  --report junit --output '/Users/jdoshi/Documents/Jinesh/ios/code/collate_errors/fastlane/test_output/report.junit' --report html --output '/Users/jdoshi/Documents/Jinesh/ios/code/collate_errors/fastlane/test_output/report.html' --report junit --output '/var/folders/_v/385bsl711hj8mg07gcv518y80000gn/T/junit_report20191016-58813-r4hkz5'
[15:40:09]: ▸ Loading...
[15:40:11]: ▸ Test build Succeeded
+--------------------+---+
|      Test Results      |
+--------------------+---+
| Number of tests    | 0 |
| Number of failures | 0 |
+--------------------+---+

nm: invalid option -- U

Not offhand. It is stating that the -U option for nm is not valid. Which is very strange. Is this running on a Mac? Have the Command Line Tools been installed? Have they been corrupted?

@lyndsey-ferguson
Copy link
Owner

With regards to this:

Enable_testability is on and xctest file does exist. However I get this message at the beginning of the run. Do you think this has anything to do with missing tests?
Ignoring byebug-11.0.1 because its extensions are not built. Try: gem pristine byebug --version 11.0.1

This is just stating that the run cannot use the byebug gem. I don't think it would cause the code to determine that there are no tests. I think that the problem is that the nm -U command is failing to pull the tests out of the xctest binary file.

You could try adding another breakpoint once you get byebug installed properly. When your Fastfile breaks at the byebug breakpoint, create a new breakpoint b XCTestList.objc_tests and walk through the code to see why the nm -U ... system command fails.

@jineshqa
Copy link
Contributor Author

I tried to run tests with xcodebuild and it ran just fine. So I'm not sure what is causing this. Command line tools are solid.

@jineshqa
Copy link
Contributor Author

@lyndsey-ferguson I feel terrible for wasting your time. I think you should just go ahead and merge this PR. Someone already confirmed that it is working for them.

@lyndsey-ferguson
Copy link
Owner

Ok...I have to clean it up a bit, I'll do that and you'll see it merged soon.

@lyndsey-ferguson
Copy link
Owner

Fixed in v3.8.7

@jineshqa
Copy link
Contributor Author

@lyndsey-ferguson didn't want to spam by creating a new issue but I am seeing this after upgrading to latest version of the plugin. Kindly let me know if I should create a new issue or it is just me.

https://pastebin.com/DricQwqh

@lyndsey-ferguson
Copy link
Owner

Ug.

@lyndsey-ferguson
Copy link
Owner

I don't have time to test, but it looks like it is using the new apis. Sorry for this.

@jineshqa
Copy link
Contributor Author

Please do not apologize...you are doing awesome work for the community.

@lyndsey-ferguson
Copy link
Owner

This is not professional to drop a broken gem out there.

@jineshqa
Copy link
Contributor Author

Well, @szymon-kazmierczak tested and it was working for him. It could be just me.

@lyndsey-ferguson
Copy link
Owner

No, I refactored the code and didn't adequately test it.

@lyndsey-ferguson
Copy link
Owner

@jineshqa, can you modify your Pluginfile per my instructions below, run bundle install, and then run your fastlane again (with the --verbose flag)?

Pluginfile:

gem 'fastlane-plugin-test_center', :git => "https://github.com/lyndsey-ferguson/fastlane-plugin-test_center.git", :branch => "issue-145-fix-broken-gem-release"

If there are still problems, please let me know and attach the console output as a text file to this issue (makes it easier for me to review). If it works, please let me know.

@lyndsey-ferguson
Copy link
Owner

@jineshqa are you doing it now? Have you tested it yet?

Just kidding 😄. Let me know when you've had a chance to look at it.

@jineshqa
Copy link
Contributor Author

Hi @lyndsey-ferguson, it is working fine now. That was a nice quick turn around.

@lyndsey-ferguson
Copy link
Owner

truly fixed in v3.8.8

@jineshqa
Copy link
Contributor Author

Fix verified on fastlane-plugin-test_center (3.8.10).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants