-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature Request: Add the option to be able to append multiple photos into a test #102
Comments
@NicoForce Do you have idea how to do that? Because currently by rely on jasmine calling our specDone function... |
I'll give it a try on the weekend to see if I can make it work. I'll comment here on any update. |
Merging same request from issue #71 (now closed because included here) Citation from @tocDK:
Citation from @Aalokit
|
Merging similar request from issue #88 (now closed because included here)
|
Merging similar request from issue #85 (now closed because included here) While this could be a even more specialized variant because we would have to check the element locator itself and not just the failed expectation Citation from @amedvedjev
|
Merging similar request from issue #61 (now closed because included here)
See original issue below for full content (including source code) |
Just came back from long vacations, Found myself modifying the index.js file but it seems autogenerated, can you explain how this index.js gets all its content? |
"Long vacations"...Happy you |
The npm link will enable you to use you local development npm package instead the npm servers, so dont have to hack in your node_modules folder directly.... |
Yeah, I have my own testing project, I was modifying the app folder, no wonder things weren't changing when I run my test many times. I had to do app:compile 😝 Thanks for suggesting the npm link, I've had to use it before for some hacky mainframe automation npm libraries. I'll update if I make anything work. |
I'm going to update what I've changed so far in protractor beautiful reporter. I didn't manage to append multiple photos yet, but I did make the report not only take browser screenshots, but to take screenshot of whatever is on the screen. I made this due to personal requirements, since I'm also automating an AS400 screen, simultaneously. Examples as to why I would want to do this are, to add screenshots of applications that are outside the browser, such as an AS400 screen, a PDF, Word Document, Excel, Desktop Application and so on. In the reporter.js file, I imported the following libraries:
In the _takeScreenShotAndAddMetaData method, I changed the last if containing the browser screenshot to the following, using the above mentioned libraries:
Take notice of 'Captura.exe', which will take care of taking the screenshot. Since the library expects an image in base64 encoding, I convert the .jpg generated by the .exe to store it for the report. For reference, I tried with the following libraries in order to take the screenshot, but none of these worked: PD: This Solution only works for Windows OS, I'm particularly working on Windows 7. |
As for how to change between application screens in the middle of the test, I used the following: In a class I use as a Base for all other classes:
The function user32.findWindowA will ask for either the class or the title of the window you want to bring to the foreground, so I used AutoIt Inspector to get either the class or title of whatever window I plan to take a screenshot of. PD: This Solution only works for Windows OS, I'm particularly working on Windows 7. x2 In case of tl;dr, I still haven't managed to solve the issue's main problem but I'll keep working on it. |
Could we get screenshots for failed expectations? Protractor FAQ mentions how to do this:
|
Is this still being worked on? I would like to help but have not idea where to start tbh. |
Quite interesting, would be nice to be implemented. |
Currently, there's only one screenshot taken per test, but I'd like to be able to add multiple screenshots per test and be able to see them all in the report.
I was going to start modifying the library just for the small project I'm doing, but I guesses it would be better to create an issue here first.
I'll attach a picture example of how I want it to work to make my request more understandable.
The text was updated successfully, but these errors were encountered: