Ryan YatesConsultant

Just a dude in his 30's doing things in Tech & trying to break the stigma's around talking about Mental Health
This is the personal blog site of Ryan Yates

In IT - Specialising in PowerShell, Automation, DevOps, Azure & Office 365
Outside of IT - Music, Psychology/Mental Health, Science, Law & Politics
There are 73 posts on this blog

There are currently 8 drafts in progress

Functional / Non-Functional Pester Tests and why I think you really should have a form of both.

So in this blog post I’m going to cover why there is a need to create Functional & Non-Functional Pester Tests for your PowerShell Modules but before I get into the nitty gritty into the whys behind creating both let me explain what the real differences are between the two because it may not be something that you have previously thought about or considered in your journey up until this point.

Recap of a Long February, March, April and May - Events Events Events!

I had intended that I would be doing a recap type post at the end of every month however I’ve been very busy so haven’t been able to do so for a number of months – that and I had an issue with my blog being offline for a few weeks. Let us start with a recap on the amount of events that I managed to attend and I think that you can see that I did a lot of travelling and attending a number of different user groups.

Creating a set of simple Pester Tests for existing or old PowerShell Modules & making them easier to update in future.

I have long thought of a way to Automagically create some Pester Tests for the Functions contained in a module that perhaps was developed before Pester was really well known. At that Point we may have been creating psm1 files that contained a number of nested functions within them. I know for one that I am one that did this / added to existing modules that were built this way – have a look at SPCSPS on Github or aka SharePointPowerShell on CodePlex as one of the first projects that I got involved with in the Open Source world.

How to find Local User Groups & events - My Experience

I had a discussion last night via twitter with one of the attendees that I met at the Microsoft Cloud Roadshow in London earlier this year and the outcome of the conversation was that although I find it easy to find out about events – this isn’t all that common for others. So I decided that I would quickly jot down some of the places that can be useful to search to find events that are going on around you.

The Pains of Poor/Missing Documentation

There will be a time where you are attempting a new task, whether that is personally or professionally and you find yourself having to resort to the documentation of the product to get to the end goal, whether that be to put together a new piece of furniture, preparing an exquisite meal or bashing different bits of software together from different companies or more commonly the same company. One thing that is common in all these scenarios is that if the documentation is completely missing then you are forced down the road where you take the “pot luck”/”educated” guess to get to the desired end result and sometimes that can lead to some hilarious results, especially if it is in relation to cooking or building furniture.

Building A Lab using Hyper-V and Lability - The End to End Example

Warning – this post is over 3800 words long and perhaps should have been split into a series – however I felt it best to keep it together – Make sure you have a brew (or 2) to keep you going throughout reading this In this post we will be looking at how you can build a VM Lab environment from pretty much scratch. This maybe for testing SharePoint applications, SQL Server, Exchange or could be for additional peace of mind when deploying troublesome patches.

Awarded the MVP Award – What this means to me and the future for the community

The MVP Award is defined by Microsoft as the below Microsoft Most Valuable Professionals, or MVPs, are community leaders who’ve demonstrated an exemplary commitment to helping others get the most out of their experience with Microsoft technologies. They share their exceptional passion, real-world knowledge, and technical expertise with the community and with Microsoft. This means that within the different areas of the Microsoft Stack there are those out there that really believe that the world can be a better place when we come together as a united front and share the knowledge that we have.

Congratulations 2016 Microsoft MVP!

This is just a very quick post to give my Congratulations to all the New and Renewed MVP’s that have and continue to make the community a much better place. I wasn’t one of them this time around but perhaps that will change in the future

Fooled Ya! Today I became a MVP!

Well only if you read this post This is an exceptional honour to have been awarded the MVP for Cloud and DataCentre Management and to me this kinda feels like an early birthday present from Microsoft (my birthday is on Monday) This isn’t something that I ever expected to achieve however it is a recognition from Microsoft themselves of the work that I have previously done for the community. I started off down the community path only last year in that time I have made some amazing friends and met a number of other MVP’s along the way.

Invoking PSScriptAnalyzer in Pester Tests for each Rule

This is a quick walkthrough on how you can get output from PSScriptAnalyzer rules in your Pester tests. So you’ll need Pester ( Version 3.4.0 or above ) PSScriptAnalyzer ( Version 1.4.0 or above ) Please note this is shown running on PowerShell v5 as part of Windows 10 Build 14295 – results may vary on other PowerShell Versions In the nature of the way we want to work we may have new ScriptAnalyzer rules in the near future (new version / additional community additions / your own custom ScriptAnalyzer rules etc) and we would want ensure that we test for them all without having to change much of the below code

C’Ya Manchester - Hello Derby!!

After yet more changes in my housing see my previous post for a bit of background link – I have decided to settle in Derby and this has been for a few very good reasons. I’ve got a good group of friends here. Manchester, London, Nottingham, Birmingham & Wolverhampton are all short train journeys away and I’m expecting to spend more time between them in the coming months ahead. I almost moved here back in January – but I decided to try and give Manchester another go from the work perspective and this seemingly wasn’t to be the case However I made a good group of friends in Manchester at the various events I’ve been to there over the last 2 years (more so the last year – see this page for more details) and I’ll still be trying to attend some of the amazing events there when it is feasible.

Pulling the Community Together to Improve the Quality of PowerShell Modules

In a discussion that started on Twitter a while back with June Blender about the quality of the Modules being posted to the PowerShell Gallery I had an Idea on a way that we could help improve this from the community – using the tools that we have available to us and more importantly the expertise of the rest of the community to help shape and guide the direction for modules.

The Power of the Humble Pint and the Community when things are difficult!

Disclaimer This isn’t a fun post (to read or to write) and nor is it a technical post – this is a reflection on the last few years and is in its very nature quite a personal post. I expect that there will be some kick backs about this post in future and I would humbly ask that you try and imagine yourself having been in my shoes at the time of these events happening and also at the time of writing this post.

Updated! Quick Win – Install PowerShell Package Management on systems running PowerShell v3 / v4

Update 9th March 2016 - PowerShell Team released an updated version of the PackageManagement modules today and I’ve updated the Script accordingly and will install the latest PackageManagement modules for you with a little verbose output Updated Microsoft blog is at https://blogs.msdn.microsoft.com/powershell/2016/03/08/package-management-preview-march-2016-for-powershell-4-3-is-now-available/ This is a very very quick post about the latest feature being made available downlevel from Powershell v5. As Microsoft have released PackageManagement (formally OneGet) that is now avaliable for PowerShell v3 & v4 as detailed in this link http://blogs.

Beware where you place Comment based Help

In working on the PSWordPress Module that Stephen Owen (@foxdeploy) has started I came across an interesting issue after running my Pester tests which calls - $ModuleFunction.Definition.Contains(’.Synopsis’) | Should be True to check for comment based help - and it was failing even though I had Comment Based help in there. The problem was that the Help was Above the Function Keyword - so this means that it wasn’t carried through to the $ModuleFunction.