UI automation framework based on python2 + selenium 3 + pytest4

Environment: Python 2 7.10, selenium3.141.0, pytest4.6.6, pytest-html1.22.0, Windows-7-6.1.7601-SP1 characteristic: Secondary encapsulation of selenium makes it more convenient to write Case.Adopt PO design idea, one page per page Py, in which the elements and operation methods are defined; In TestCase, directly call the operation method ...

Added by f1nutter on Tue, 11 Jan 2022 14:13:34 +0200

Django project creation and life process

1, Creation of Django project 1. Project creation and operation Install Django module Open pycharm and install the Django module in the Terminal interactive interface Note: different versions may be slightly different in the use of the framework. Select the version as needed. pip install django==2.0 Import the module in the python co ...

Added by blufish on Tue, 11 Jan 2022 10:38:40 +0200

Very practical Python library, push a fire once!

Life is short, learn Python!Python is a great language. It is one of the fastest growing programming languages in the world. Again and again, it has proven its usefulness in developer positions and cross industry data science positions. The entire ecosystem of Python and its libraries makes it a suitable choice for users around the world (begin ...

Added by stickman373 on Tue, 11 Jan 2022 09:33:14 +0200

[Python learning] automatically generate java code

There is a requirement in the project that a base class has a comparison method and a Copy method. In some places, these two methods need to be called frequently. For all subclasses, you need to override these two methods and maintain some member variables within the class. For example, there is a variable M_ Imyval, this needs to be maintaine ...

Added by narimanam on Tue, 11 Jan 2022 06:09:44 +0200

python virtual environment management summary

Creation and use of python virtual environment As a newcomer, I never thought about Python virtual environment management. I thought that all the libraries I want to use are installed together. How good it is to use direct import. However, later, I learned more and more. I not only shed tears of regret, but this time, I caught all the ...

Added by matrixd on Tue, 11 Jan 2022 03:59:09 +0200

Some advanced features of Python

Some advanced features of Python Advanced features List generation 1. When writing a list generator, put the element x **2 to be generated in front, followed by a for loop, which is a general usage. >>> b = [x**2 for x in range(0,11)] >>> b [0, 1, 4, 9, 16, 25, 36, 49, 64, 81, 100] 2. List generation can also output ...

Added by alvinshaffer on Tue, 11 Jan 2022 01:57:21 +0200

python notes -- things about classes and objects

python everything is an object All but a few statements in python are objects! Create a class, which is called a class object. It also occupies memory space and has its value. class Student: pass print(id(Student)) #2926222013040 print(type(Student)) #<class 'type'> print(Student) #<class 'main_.student'> Composition of ...

Added by dwees on Tue, 11 Jan 2022 01:20:09 +0200

Python Basics - day 6

Python Basics - day 6 Slicing operations for lists Indexing and slicing Positive index: 0 ~ N-1 / negative index: - N ~ -1 nums = [1, 2, 3, 4, 5, 6] print(nums[2:]) # Gets the elements after index 2, including the elements with index 2 print(nums[::]) # Get all elements print(nums[::-1]) # Invert all elements print(nums[ ...

Added by only one on Mon, 10 Jan 2022 23:38:21 +0200

Using Ancol PCA method, the results of ancestral source calculator are combined with the actual situation for visual analysis

preface Do you have 10000 friends who see the problem ❓ Do you want to ask what the hell Ancol PCA is. I don't know normal, because I made the word 2333333 Why it's called this name: as we all know, the English of descent is Ancestry, and the English of location is location. These two words take the first three letters, loc and then reverse ...

Added by kid85 on Mon, 10 Jan 2022 22:00:19 +0200

python: create blog demo with python+django for the first time (blog implementation - 2. Define user model classes)

User model class 1. Django default user authentication system (knowledge introduction) 1. Django has its own user authentication system It handles user accounts, groups, permissions, and cookie based user sessions 2. Django certification system location django.contrib.auth contains the core of the authentication framework and the default ...

Added by xfluous on Mon, 10 Jan 2022 21:15:13 +0200