fastlane-old / screengrab Goto Github PK
View Code? Open in Web Editor NEWAutomated localized screenshots of your Android app on every device
Home Page: https://fastlane.tools
Automated localized screenshots of your Android app on every device
Home Page: https://fastlane.tools
Hello there,
I notice that after running screengrab on my phone to take some screenshots, the language set on it has changed.
My phone was in it
before the tests. I took screenshots in en
, it
and es
(in this order) and after it, the language was en
.
We should set the original language back once tests are completed.
Thanks
As frameit (https://github.com/fastlane/frameit) only considers iOS it would be nice if there was an option to automatically add a device frame to the captured screenshot.
On Ubuntu 14.
/var/lib/gems/2.2.0/gems/fastlane_core-0.36.4/lib/fastlane_core/command_executor.rb:47:in each': [!] Input/output error @ io_fillbuf - fd:8 /dev/pts/30 (Errno::EIO) from /var/lib/gems/2.2.0/gems/fastlane_core-0.36.4/lib/fastlane_core/command_executor.rb:47:in
block in execute'
from /var/lib/gems/2.2.0/gems/fastlane_core-0.36.4/lib/fastlane_core/command_executor.rb:46:in spawn' from /var/lib/gems/2.2.0/gems/fastlane_core-0.36.4/lib/fastlane_core/command_executor.rb:46:in
execute'
from /var/lib/gems/2.2.0/gems/screengrab-0.2.0/lib/screengrab/runner.rb:80:in select_device' from /var/lib/gems/2.2.0/gems/screengrab-0.2.0/lib/screengrab/runner.rb:52:in
run'
from /var/lib/gems/2.2.0/gems/screengrab-0.2.0/bin/screengrab:39:in block (2 levels) in run' from /var/lib/gems/2.2.0/gems/commander-4.3.5/lib/commander/command.rb:178:in
call'
from /var/lib/gems/2.2.0/gems/commander-4.3.5/lib/commander/command.rb:178:in call' from /var/lib/gems/2.2.0/gems/commander-4.3.5/lib/commander/command.rb:153:in
run'
from /var/lib/gems/2.2.0/gems/commander-4.3.5/lib/commander/runner.rb:428:in run_active_command' from /var/lib/gems/2.2.0/gems/fastlane_core-0.36.4/lib/fastlane_core/ui/fastlane_runner.rb:23:in
run!'
from /var/lib/gems/2.2.0/gems/commander-4.3.5/lib/commander/delegates.rb:15:in run!' from /var/lib/gems/2.2.0/gems/screengrab-0.2.0/bin/screengrab:56:in
run'
from /var/lib/gems/2.2.0/gems/screengrab-0.2.0/bin/screengrab:62:in <top (required)>' from /usr/local/bin/screengrab:23:in
load'
from /usr/local/bin/screengrab:23:in `
Like a lot of devs out here, I am developing on Windows (my main machine)
The source of the screengrab binary is (what looks like) linux style bash code.
I suppose it can't be run with cygwin?
Thanks,
Tim
Hi guys,
I trying start screengrab in Ubuntu with Android project.
My way: call screengrab in terminal -> put package -> see error with exitstatus.
After sudo gem install fastlane
I sow error like use ruby >= 2.2.2
So, ruby was updated up to 2.3.
But problem hasn`t gone.
Please, see log below error message
while running screengrab
and fastlane.
Does fastlane need install for correct work with screengrab?
Could you help me?
~ $ screengrab
.......
$ adb devices -l
[12:55:24]: ▸ List of devices attached
😨 An error occured. Please enable crash reports using fastlane enable_crash_reporting
.
👍 This makes resolving issues much easier and helps improve fastlane.
🔒 The reports will be stored securely on getsentry.com.
/var/lib/gems/2.1.0/gems/fastlane_core-0.36.8/lib/fastlane_core/command_executor.rb:79:in execute': [!] undefined method
exitstatus' for nil:NilClass (NoMethodError)
from /var/lib/gems/2.1.0/gems/screengrab-0.2.1/lib/screengrab/runner.rb:80:in select_device' from /var/lib/gems/2.1.0/gems/screengrab-0.2.1/lib/screengrab/runner.rb:52:in
run'
from /var/lib/gems/2.1.0/gems/screengrab-0.2.1/bin/screengrab:39:in block (2 levels) in run' from /var/lib/gems/2.1.0/gems/commander-4.3.5/lib/commander/command.rb:178:in
call'
from /var/lib/gems/2.1.0/gems/commander-4.3.5/lib/commander/command.rb:178:in call' from /var/lib/gems/2.1.0/gems/commander-4.3.5/lib/commander/command.rb:153:in
run'
from /var/lib/gems/2.1.0/gems/commander-4.3.5/lib/commander/runner.rb:428:in run_active_command' from /var/lib/gems/2.1.0/gems/fastlane_core-0.36.8/lib/fastlane_core/ui/fastlane_runner.rb:23:in
run!'
from /var/lib/gems/2.1.0/gems/commander-4.3.5/lib/commander/delegates.rb:15:in run!' from /var/lib/gems/2.1.0/gems/screengrab-0.2.1/bin/screengrab:56:in
run'
from /var/lib/gems/2.1.0/gems/screengrab-0.2.1/bin/screengrab:62:in <top (required)>' from /usr/local/bin/screengrab:23:in
load'
from /usr/local/bin/screengrab:23:in `
current directory: /var/lib/gems/2.3.0/gems/unf_ext-0.0.7.2/ext/unf_ext
/usr/bin/ruby2.3 -r ./siteconf20160301-30575-gfbvtm.rb extconf.rb
mkmf.rb can't find header files for ruby at /usr/lib/ruby/include/ruby.h
extconf failed, exit code 1
Gem files will remain installed in /var/lib/gems/2.3.0/gems/unf_ext-0.0.7.2 for inspection.
Results logged to /var/lib/gems/2.3.0/extensions/x86_64-linux/2.3.0/unf_ext-0.0.7.2/gem_make.out
~ $
Thanks for your help.
When I'm adding the dependency to my project:
androidTestCompile 'tools.fastlane:screengrab:0.2.0'
I get the message:
Failed to resolve: 'tools.fastlane:screengrab:0.2.0'
Am I missing something?
Hello, screengrab is a great tool and it helped us a lot in getting the new screen shots for store! Really 5 stars. I had a problem tho. I had to wait some time in order to take the screen shot because I had to wait for images to load or for the view to be fully loaded. So I did this helper https://gist.github.com/Peddro/1d6cafc72a9d77c274b7 in order to achieve this.
I guess we can say it's kind of a hack but it helped with the problem. Was wondering if you have any plans to integrate a delayed screenshot or maybe there would be a way to integrate my solution into screengrab?
Hi there is some problem with capturing all popups.
I mean AlertDialog, FragmenDialog, ProgressDialog.
Of course I using support library and
// capture screen
androidTestCompile 'tools.fastlane:screengrab:0.3.0'
// screen testing
androidTestCompile 'com.android.support:support-annotations:23.2.0'
androidTestCompile 'com.android.support.test:runner:0.4.1'
androidTestCompile 'com.android.support.test:rules:0.4.1'
// Optional -- UI testing with Espresso
androidTestCompile 'com.android.support.test.espresso:espresso-core:2.2.1'
// Optional -- UI testing with UI Automator
androidTestCompile 'com.android.support.test.uiautomator:uiautomator-v18:2.1.1'
androidTestCompile 'com.android.support.test.espresso:espresso-intents:2.2.1'
There isn't popup in screen and keyboard when it's opened.
I've found
#75
#82
but I decided to create new issue.
There is my log
03-04 19:05:46.467 2323-2323/com.myapp D/Screengrab: Using screenshot storage directory: /storage/emulated/0/com..myapp/screengrab/en-GB/images/screenshots
03-04 19:05:47.064 2323-2323/com..myapp D/Screengrab: Captured screenshot "1457111146467_account_screen_before.png"
03-04 19:05:51.103 2323-2323/com..myapp D/Screengrab: Using screenshot storage directory: /storage/emulated/0/com..myapp/screengrab/en-GB/images/screenshots
03-04 19:05:51.767 2323-2323/com..myapp D/Screengrab: Captured screenshot "1457111151103_account_screen_before.png"
Could you help me?
Thanks in advance.
screengrab has moved to the fastlane main repo. Please create your issue there, thanks!
Screengrab looks awesome, but there is just a little quirk, the systembar is not shown (except for the color), and also the button bar (of buttonless devices like nexus) are only a black rectangle.
I don't know if you have some ways to workaround that (like adding the bar manually using command like convert), but if you don't, you could use UIAutomator.
It provides a method takeScreenshot(File) from the class UIDevice that take a complete screenshot of the device, system bar and button bar included.
It requires a minSdk 18, but it's easy to work around that (using a product flavor, for example).
As most of android developers know, you can capture the screenshot with frame screenshot option so you can change the skin as nexus 5x and add drop shadow on it and also can add screen glare.
Does this tool have all of this features? or just changes the localization of application and captures the screenshot like a script?
Thanks.
/var/lib/gems/2.0.0/gems/fastlane_core-0.36.4/lib/fastlane_core/command_executor.rb:47:in each': [!] Input/output error - /dev/pts/17 (Errno::EIO) from /var/lib/gems/2.0.0/gems/fastlane_core-0.36.4/lib/fastlane_core/command_executor.rb:47:in
block in execute'
from /var/lib/gems/2.0.0/gems/fastlane_core-0.36.4/lib/fastlane_core/command_executor.rb:46:in spawn' from /var/lib/gems/2.0.0/gems/fastlane_core-0.36.4/lib/fastlane_core/command_executor.rb:46:in
execute'
from /var/lib/gems/2.0.0/gems/screengrab-0.2.0/lib/screengrab/runner.rb:80:in select_device' from /var/lib/gems/2.0.0/gems/screengrab-0.2.0/lib/screengrab/runner.rb:52:in
run'
from /var/lib/gems/2.0.0/gems/screengrab-0.2.0/bin/screengrab:39:in block (2 levels) in run' from /var/lib/gems/2.0.0/gems/commander-4.3.5/lib/commander/command.rb:178:in
call'
from /var/lib/gems/2.0.0/gems/commander-4.3.5/lib/commander/command.rb:178:in call' from /var/lib/gems/2.0.0/gems/commander-4.3.5/lib/commander/command.rb:153:in
run'
from /var/lib/gems/2.0.0/gems/commander-4.3.5/lib/commander/runner.rb:428:in run_active_command' from /var/lib/gems/2.0.0/gems/fastlane_core-0.36.4/lib/fastlane_core/ui/fastlane_runner.rb:23:in
run!'
from /var/lib/gems/2.0.0/gems/commander-4.3.5/lib/commander/delegates.rb:15:in run!' from /var/lib/gems/2.0.0/gems/screengrab-0.2.0/bin/screengrab:56:in
run'
from /var/lib/gems/2.0.0/gems/screengrab-0.2.0/bin/screengrab:62:in <top (required)>' from /usr/local/bin/screengrab:23:in
load'
from /usr/local/bin/screengrab:23:in `
Error executing screengrab:
/usr/local/lib/ruby/gems/2.3.0/gems/fastlane_core-0.36.7/lib/fastlane_core/command_executor.rb:46:in
spawn': [!] No such file or directory - fork failed (Errno::ENOENT)
from /usr/local/lib/ruby/gems/2.3.0/gems/fastlane_core-0.36.7/lib/fastlane_core/command_executor.rb:46:in execute' from /usr/local/lib/ruby/gems/2.3.0/gems/screengrab-0.2.0/lib/screengrab/runner.rb:80:in
select_device'
from /usr/local/lib/ruby/gems/2.3.0/gems/screengrab-0.2.0/lib/screengrab/runner.rb:52:in run' from /usr/local/lib/ruby/gems/2.3.0/gems/screengrab-0.2.0/bin/screengrab:39:in
block (2 levels) in run'
from /usr/local/lib/ruby/gems/2.3.0/gems/commander-4.3.5/lib/commander/command.rb:178:in call' from /usr/local/lib/ruby/gems/2.3.0/gems/commander-4.3.5/lib/commander/command.rb:153:in
run'
from /usr/local/lib/ruby/gems/2.3.0/gems/commander-4.3.5/lib/commander/runner.rb:428:in run_active_command' from /usr/local/lib/ruby/gems/2.3.0/gems/fastlane_core-0.36.7/lib/fastlane_core/ui/fastlane_runner.rb:23:in
run!'
from /usr/local/lib/ruby/gems/2.3.0/gems/commander-4.3.5/lib/commander/delegates.rb:15:in run!' from /usr/local/lib/ruby/gems/2.3.0/gems/screengrab-0.2.0/bin/screengrab:56:in
run'
from /usr/local/lib/ruby/gems/2.3.0/gems/screengrab-0.2.0/bin/screengrab:62:in <top (required)>' from /usr/local/bin/screengrab:23:in
load'
from /usr/local/bin/screengrab:23:in <main>'
screengrab version: 0.2.0
Mac OSX version: 10.11.3
ruby version: 2.3.0p0
you use
sudo gem install screengrab
but what should i do in windows ?
I am having an issue screen grabbing when a Material Dialog (https://github.com/afollestad/material-dialogs) is shown. Here is the detailed log:
[17:04:16]: ▸ com.xxx.xxx.Test:..
[17:04:16]: ▸ Error in shouldXXX(com.xxx.xxx.Test):
[17:04:16]: ▸ java.lang.ClassCastException: android.view.ContextThemeWrapper cannot be cast to android.app.Activity
[17:04:16]: ▸ at tools.fastlane.screengrab.Screengrab$1.perform(Screengrab.java:77)
[17:04:16]: ▸ at android.support.test.espresso.ViewInteraction$1.run(ViewInteraction.java:144)
[17:04:16]: ▸ at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:422)
[17:04:16]: ▸ at java.util.concurrent.FutureTask.run(FutureTask.java:237)
[17:04:16]: ▸ at android.os.Handler.handleCallback(Handler.java:739)
[17:04:16]: ▸ at android.os.Handler.dispatchMessage(Handler.java:95)
[17:04:16]: ▸ at android.os.Looper.loop(Looper.java:135)
[17:04:16]: ▸ at android.app.ActivityThread.main(ActivityThread.java:5254)
[17:04:16]: ▸ at java.lang.reflect.Method.invoke(Native Method)
[17:04:16]: ▸ at java.lang.reflect.Method.invoke(Method.java:372)
[17:04:16]: ▸ at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:903)
[17:04:16]: ▸ at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:698)
[17:04:26]: ▸ .
[17:04:26]: ▸ Time: 39.824
[17:04:26]: ▸ There was 1 failure:
[17:04:26]: ▸ 1) shouldTakeScreenshotInputDestination(com.xxx.xxx.Test)
[17:04:26]: ▸ java.lang.ClassCastException: android.view.ContextThemeWrapper cannot be cast to android.app.Activity
[17:04:26]: ▸ at tools.fastlane.screengrab.Screengrab$1.perform(Screengrab.java:77)
[17:04:26]: ▸ at android.support.test.espresso.ViewInteraction$1.run(ViewInteraction.java:144)
[17:04:26]: ▸ at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:422)
[17:04:26]: ▸ at java.util.concurrent.FutureTask.run(FutureTask.java:237)
[17:04:26]: ▸ at android.os.Handler.handleCallback(Handler.java:739)
[17:04:26]: ▸ at android.os.Handler.dispatchMessage(Handler.java:95)
[17:04:26]: ▸ at android.os.Looper.loop(Looper.java:135)
[17:04:26]: ▸ at android.app.ActivityThread.main(ActivityThread.java:5254)
[17:04:26]: ▸ at java.lang.reflect.Method.invoke(Native Method)
[17:04:26]: ▸ at java.lang.reflect.Method.invoke(Method.java:372)
[17:04:26]: ▸ at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:903)
[17:04:26]: ▸ at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:698)
[17:04:26]: ▸ FAILURES!!!
[17:04:26]: ▸ Tests run: 4, Failures: 1
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.