Screenpy

Latest version: v4.2.4

Safety actively analyzes 628918 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 4 of 7

3.2.1

------------------

Bugfixes

- Updated `See` and `MakeNote` typehints now that they allow for bare values *and* Questions.

3.2.0

------------------

Breaking Changes

- The gravitas levels have moved from `screenpy.pacing` to `screenpy.narration.narrator`, and they've also changed terminology. The updated terminology is more generic, describing how serious the gravitas is. The gravitas level is passed along to the adapters to be used or ignored as needed.

New Features

- Added a `Narrator` class, who handles all the reporting! The Narrator's microphone can be outfitted with different adapters to report to whatever reporting service you want. Included are the new `AllureAdapter` and `StdOutAdapter`, which will maintain existing behavior.
- (h/t langgaibo) Added an `IsCloseTo` resolution!
- (h/t bandophahita) Added an `Eventually` action!

Improvements

- Part of the above `Narrator` addition is that there is now a way for you to manually control logging, either by putting the narrator `off_the_air` or by making their `microphone_cable_kinked`. It was immediately handy for `Eventually`, maybe you'll find it useful, too!
- Better typehints for `Target`!
- Better `beat` for `MakeNote`!
- `See` and `MakeNote` can now both accept values *and* Questions!

Bugfixes

- XPATH locators which begin with a parenthesis are now correctly recognized as XPATH locators.

3.1.2

------------------

Improvements

- I'm on a tear, eh?
- Added a more useful test in `screenpy-quickstart` that shows off more actions.
- Adjusted the return type of the `noted_under` direction from `object` to `Any`. I think it could be something more specific, but `Any` is the best i've got for now.

3.1.1

------------------

Improvements

- Added `.of_all` method to the **Attribute** Question because that is, incidentally, the way i needed to be able to use it. Woops!

3.1.0

------------------

New Features

- (h/t langgaibo and sramdas-dod) Actors can now clean up after themselves! Give 'em a task with `.has_cleanup_task(CleanUpTask())` and they'll do the `CleanUpTask()` task as they exit. Or sooner, if you call `Actor.cleans_up()` yourself! (`CleanUpTask` not included.)
- (h/t langgaibo) Actors can now take notes and use them... anywhere. The new **MakeNote** Action allows you to save the answer to a Question under a handy key, which can then be recalled later using the `noted_under` direction! Which brings me to...
- The Director! The Director is omnipresent and singular. They are always watching, waiting to take or give a needed note. Ask for one by using a `the_noted(key)` or `noted_under(key)` direction, wherever you need the information they hold. πŸ”ΊπŸ‘πŸ”Ί
- Added the **See**, **SeeAllOf**, and **SeeAnyOf** Actions, to relieve Actors of the burden of asserting. Take a look at the new [Deprecations](https://screenpy-docs.readthedocs.io/en/latest/deprecations.html#id3) docs page to learn more.
- Added the **Attribute** Question, to ask about an element's attributes. Like "value", which is the one i'll be asking about.

Improvements

- (h/t WandyYing and bandophahita) SOLIDified Actors a little bit more by deprecating their asserting responsibility. This was part of adding the new **See** etc. Actions mentioned above. Actors now have a `should` method, which is really just an alias for `was_able_to` and `attempts_to`, but is meant to be used with that **See** Action. Or not, it's really up to you.
- Targets can now be used as if they themselves were locator tuples. You can do `target[0]` and pass in `*target`s. It's wild! And cleans up a really gross list comprehension from the **Wait** source code.
- As ever, another huge documentation update. Things should be more consistent now. Maybe. (I'll probably find more things to smooth out as soon as i commit this.) (*Edit*: i did.)

Deprecations

- Deprecated `Actor.should_see_the` and `Actor.should_see_any_of` in favor of using `Actor.should` with the new **See**, **SeeAllOf**, and **SeeAnyOf** Actions. These methods will be removed in 4.0.0. Instructions for modifying your tests can be found in the [3.1.0 Deprecations documentation](https://screenpy-docs.readthedocs.io/en/latest/deprecations.html#id3)

3.0.4

------------------

Bug Fixes

- Missed a `from typing import Protocol`, that's fixed now. Woops!

Page 4 of 7

Β© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.