Git Product home page Git Product logo

python-testing-presentation's Introduction

This is a presentation/workshop on various testing technologies in Python. It's built using RISE, a jupyter notebook-based presentation system using reveal.js.

Installation

First you need to install the Python stuff (probably in a virtual environment):

pip install -r requirements.txt

Installing the RISE slideshow extension

After this install the RISE jupyter extensions. Note that you may need to reactivate your virtual environment for your shell to properly see the commands:

jupyter nbextension install rise --py --sys-prefix
jupyter nbextension enable rise --py --sys-prefix

Installing the Jupyter "contrib" extensions

If you want the slideshows to automatically run certain initialization cells (hint: you probably do) then you need to install the "initialization cells" extension from the Jupyter contrib extensions:

jupyter contrib nbextension install --user
jupyter nbextension enable init_cell/main

Get more info on these extensions at the project page.

NB: Running initialization cells requires that you "trust" the notebooks. You'll probably need to do this for each slideshow notebook for which you want initialization cells.

Running

First start the notebook.

cd slides
jupyter notebook

This will open a browser window with a list of notebooks. The relevant notebooks are:

  • unittest.ipynb
  • mock.ipynb
  • pytest.ipynb
  • hypothesis.ipynb
  • cosmic-ray.ipynb

Click on any of these to open them in your browser.

Then look for the icon in the notebook toolbar for running the presentation. (Hint: it looks a bit like a histogram.)

Prepping the slides

Prior to starting the notebook, you might want to run the script that prepares the slides for presentation, prep_slides.sh:

./prep_slides *.ipynb

This will execute all of the cells, clear the output, and "trust" the notebooks. This isn't strictly necessary, but it's a good way to start presentations from a known state.

python-testing-presentation's People

Contributors

abingham avatar

Stargazers

Truls Fretland avatar

Watchers

 avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.