Skip to content

Makes Selenium2Library compatible with RobotFramework 3.0 and Python 3.4, 2.7 and 2.6 - #564

Closed
HelioGuilherme66 wants to merge 37 commits into
robotframework:masterfrom
HelioGuilherme66:code_futurized
Closed

HelioGuilherme66 wants to merge 37 commits into
robotframework:masterfrom
HelioGuilherme66:code_futurized

Conversation

@HelioGuilherme66

Copy link
Copy Markdown
Member

This PR replaces #556 and contains PRs #559, #561, #562 and #563. Please merge them in order and look at commits to see changes grouped by code modification (not always ;).

…versions.

Already has some settings for Python 3.4, but disabled.
Changes Travis settings to install RobotFramework 3.0.
 under Python 2.6, 2.7 and 3.4.
Activates Python 3.4 in Travis config.
Changed files with futurize from http://python-future.org/:
   build_dist.py
   demo/demoapp/server.py
   demo/package.py
   doc/buildhtml.py
   setup.py
   src/Selenium2Library/__init__.py
   src/Selenium2Library/keywords/__init__.py
   src/Selenium2Library/keywords/_alert.py
   src/Selenium2Library/keywords/_browsermanagement.py
   src/Selenium2Library/keywords/_cookie.py
   src/Selenium2Library/keywords/_element.py
   src/Selenium2Library/keywords/_formelement.py
   src/Selenium2Library/keywords/_javascript.py
   src/Selenium2Library/keywords/_logging.py
   src/Selenium2Library/keywords/_runonfailure.py
   src/Selenium2Library/keywords/_screenshot.py
   src/Selenium2Library/keywords/_selectelement.py
   src/Selenium2Library/keywords/_tableelement.py
   src/Selenium2Library/keywords/_waiting.py
   src/Selenium2Library/keywords/keywordgroup.py
   src/Selenium2Library/locators/__init__.py
   src/Selenium2Library/locators/customlocator.py
   src/Selenium2Library/locators/elementfinder.py
   src/Selenium2Library/locators/tableelementfinder.py
   src/Selenium2Library/locators/windowmanager.py
   src/Selenium2Library/utils/__init__.py
   src/Selenium2Library/utils/events/__init__.py
   src/Selenium2Library/utils/events/event.py
   src/Selenium2Library/utils/events/scope_event.py
   src/Selenium2Library/utils/librarylistener.py
   src/Selenium2Library/webdrivermonkeypatches.py
   src/ez_setup.py
   test/lib/mockito/__init__.py
   test/lib/mockito/inorder.py
   test/lib/mockito/invocation.py
   test/lib/mockito/matchers.py
   test/lib/mockito/mock_registry.py
   test/lib/mockito/mocking.py
   test/lib/mockito/mockito.py
   test/lib/mockito/spying.py
   test/lib/mockito/verification.py
   test/resources/statuschecker.py
   test/resources/testserver/testserver.py
   test/run_tests.py
   test/unit/keywords/test_browsermanagement.py
   test/unit/utils/test_browsercache.py
Comment thread doc/generate.py Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's remove all the extraneous quotes here.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I left the quotes there because I think that it is intended to print a comment.

@just-be-dev

Copy link
Copy Markdown
Contributor

Have you looked through the 3.4 errors? There seems to be a lot of them... Lots of elements couldn't be found.

@HelioGuilherme66

Copy link
Copy Markdown
Member Author

In my last commit (8e95b3f) I changed the way how python is called, by using the version suffix. There are problems with Python3.4 ../http/server.py code. That is why the Travis is failing with Python3.4. You may verify that the demo starts the server correctly (and also other tests I have).
This is the only blocking point for us to have a green Travis build in Python3.4.

@HelioGuilherme66 HelioGuilherme66 changed the title Makes Selenium2Library compatible withRobotFramework 3.0 and Python 3.4, 2.7 and 2.6 Makes Selenium2Library compatible with RobotFramework 3.0 and Python 3.4, 2.7 and 2.6 Jan 19, 2016
@pekkaklarck

Copy link
Copy Markdown
Member

I'm sorry but this PR is so big and touches so many places that I don't have time to review and comment it in detail. Some general comments:

  • In my opinion scripts related to packaging, demo, etc. should not be touched at this point. It seems to me most of them are not used anymore and should just be removed. If some are still needed, they don't urgently need Python 3 support.
  • Travis configuration changes should get their own PR. I don't know too much about Travis and canot merge PRs touching it without knowing what change do.
  • As I have commented earlier, I would like to see separate PRs fixing individual Python 3 compatibility issues without affecting Python 2 compatibility. Two easy topics to start are:
    • Exceptions: except Exception, err -> except Exception as err.
    • Imports: from internal import Stuff -> from .internal import Stuff. This PR could also contain general cleanup to imports to make them more PEP-8 compatible. It shouldn't contain any other code changes.

Testing Pull Request Template
@aaltat

aaltat commented Jul 6, 2016

Copy link
Copy Markdown
Contributor

I think Pekka comment is still a valid one. And also the commit history is awful.

@HelioGuilherme66

Copy link
Copy Markdown
Member Author

This PR is the accumulated commits. We should analyze them in order, starting with PR #559, then after that one is merged, we go for #561, and so on. The latest commits in this one, could be discarded as they are essentially merges from master.

Update CONTRIBUTING.md

Fixes test run in Fedora.
	modified:   CONTRIBUTING.md
	modified:   src/Selenium2Library/keywords/_browsermanagement.py
@HelioGuilherme66 HelioGuilherme66 mentioned this pull request Aug 11, 2016
ombre42 and others added 6 commits October 15, 2016 00:53
* Fix 404 due to RF migration to Github

* Link to project page

* Format corrections per PR comments

* fix pronoun usage
While we are not having Selenium 3.0 working, with external `geckodriver`, we use lower versions of stable Firefox.
We are not ready for Selenium 3.0 yet.
…ramework#674)

* Added method to find element by class name robotframework#673

* Changes to use Firefox ESR (45.4.0)

While we are not having Selenium 3.0 working, with external `geckodriver`, we use lower versions of stable Firefox.

* Changes to use Selenium 2.53.6 (and not 3.0)

We are not ready for Selenium 3.0 yet.
…ilure in Fedora Core 22).

Get path to python/jython to run unit tests.
@HelioGuilherme66
HelioGuilherme66 force-pushed the code_futurized branch 2 times, most recently from b70789c to 1705d44 Compare November 27, 2016 01:37
Sets this version to 1.8.1b1.
@pekkaklarck

Copy link
Copy Markdown
Member

Most of the changes done here is already done by other PRs. This was too big PR with too many changes. to begin with.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants