PythonTesting.net is about testing stuff with python.
A great programming language with lots of uses. I’m going to assume that you are already sold on the relative usefulness of python, or you wouldn’t even be here reading this. I’m also going to assume that the reader has a pretty good basic understanding of the language. You don’t need to be an expert to use it effectively. If I use parts of the language without explanation where you feel there should be more detail, please, please, please let me know. We’re all equals here, with different areas of experience and expertise. I don’t consider myself a python guru, but I have quite a bit of experience. If there’s something confusing in a post, please let me know, and I’ll try to cover it in more detail.
Python can of course be used for all types of testing.
Unit testing is testing small pieces of a larger system. Unit testing has been covered quite a bit elsewhere. Python can be used for unit testing python scripts/programs. However, unit testing other stuff may be a bit tricky.
Much like unit testing, but with bigger pieces. Integration testing is a bit of a fuzzy term, and can mean different things to different people. It can be a lot like unit testing, but with multiple components interacting. Or it can be more like functional testing, using the outside API of a system, but only testing limited parts of the system.
I am going to cover unit testing and integration testing at just the highest levels. A lot of the topics covered will apply to unit testing and integration testing. However, I’m not going to go into either topic very deeply.
Plea to reader
I’m really not going to cover unit testing or integration testing much on this blog. However, I’d like to point people in the right direction if they make it to this page.
Please use the contact form and send me links to what you think are great resources for unit testing and integration testing.
Ah. This is the real focus of this site. When I focus on functional testing, I can now make use of python to test lots and lots of stuff outside of python.
Functional testing is testing the external interface of a, hmmm, thing.
Read more about this below.
When I make something (see ‘stuff’ below), I have an external interface, an API, a user interface, into the something. I may publish information about that interface.
In any case, I want to make sure that the interface that I’m promising to my users/clients/customers, really works the way I say it does.
That’s the idea of functional testing.
Functional testing is testing the functionality of the something that I’m making.
That’s where python really shines, I think.
I can use python to interact with just about anything I can think of that can be accessed via software.
And I can write python code faster than I can write code in most other languages.
Therefore, I’m really going to want to use python for my functional testing, if I can.
When I say “using python to test stuff”, what “stuff” am I talking about?
Lots of stuff.
To use Python to test something, I just need to have a way to access the something in python.
That opens it up to lots and lots of things.
Here’s a short-ish list:
- Python scripts and libraries (of course)
- Any piece of software with a command line interface:
** perl scripts
** bash scripts
** fill-in-the-blank scripts
- Software that exposes a COM interface
- Test instruments, such as oscilloscopes, spectrum analyzers, network analyzers, etc. that have a remote programming API.
- Any piece of hardware that I can test using one or more test instruments that are accessible via a remote interface.
- web services
Another plea to readers
What are you using python to test?
Did I miss something in my list?
Even if it’s really obscure (especially if it’s really obscure), let me know.
I want to know all of the crazy ways people are using python to test stuff.
About the author
Hi. Thanks for stopping by.
My name is Brian.
I also write very occasionally about software related stuff at Varied Thoughts.
If your really curious, you can find out more about me on linkedIn.
Why am I writing about testing with python?
There are lots of engineers that can take advantage of python to test whatever they are working on. But the information is scattered all over the internet.
I want to bring in the important bits into one place to get you up and running fast.
The point is that you don’t have to be an expert at python to effectively and efficiently use python as a testing framework. At least you shouldn’t have to be.
There are some things that are pretty complicated. And I’m sure I’m going to learn a lot about a lot of different interfaces as I go along writing this site. But that’s part of the fun. And part of the reason I’m writing this stuff.
BTW, I’ve got no problem either allowing guest posts or linking to your content elsewhere if it fits into the topic of the site. So let me know if either is interesting to you.
I’m not sure about the schedule yet.
I’m going to start by trying to get at least one or two posts up per month.