-
Notifications
You must be signed in to change notification settings - Fork 404
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tests improvments and Linux support #668
Conversation
@ili101 Good stuff! For Docker, I've been thinking it'd be interesting if I and others could pull an image down, run it and try out the the module, remove it, all without polluting the main box. If it's easy to build that sort of pipeline, then we can experiment to see if it has value. The Azure DevOps fails, strange. |
Yes It looks like it run the azure-pipelines.yml from your master and not from the PR. |
Good point, I set that up a while ago using tasks, not yaml. Looks like I need to delete it and setup another pipeline to just the yaml. |
Ok. ping me when you have the yaml pipeline active and I will push something in here to retrigger the test. |
Update regarding the AutoFitColumns() problem from #666. I just tested it on WSL and also got the problem. |
Yeah, saw EPPlus needed that lib from there nuget package. Could be that it is installed. Maybe ImportExcel needs a pre-flight check now? |
There is actually one test in the psm1 already:
|
@ili101 I setup a new pipeline, only yml, only PS 5.1. Could you poke the PR to see if it hits the same issue? |
@ili101 Thanks, looks like it is working. |
Looks good. The paused Pipeline "ImportExcel-CI" is still trying to run the test to. Maybe disable it and cancel the 2 test that are queued there. |
@ili101 Alright, going merge, a little apprehensive. Thanks for the work, really appreciate it. |
@ili101 Merged, I updated the badges. I turned on the new Az DevOps preview, not sure how to index into each job. This looks great. What's the best way to chat with you outside of GitHub? |
appveyor badge need update to:
Skype? ili1011 |
@dfinke After learning to use Docker turned out it was very simple to set up especially because I already have the Artifact ready. |
@dfinke I started using twitter recently, my user is https://twitter.com/ili_z please add me so we can chat if needed. Thank you. |
Integrated https://github.com/ili101/Module.Template. This is a simple template of a module with examples on how to integrate Pester tests and AppVeyor and Azure DevOps Pipelines. this bring:
Code Cleanup
Linux Support
$env:TEMP
with[IO.Path]::GetTempPath()
for Linux support.$env:TEMP
with TestDrive:. It's a spacial drive created by the Pester module to help manage the files used by the tests, It also automatically cleans after exiting the scope and is cross-platform.Get-Service
,Get-CimInstance
andGet-Process
that are missing or different on Linux I added Sample data so the test can be run on any platform.PS
I noticed that there are 2 orphaned files Export-charts.ps1 and GetExcelTable.ps1 that are not referenced anywhere, not sure if intentional or just forgotten to be added to the psm1.
All tests are now running on Linux and Windows I relay dislike "returning" from a test without at last reflating it in the Pester summary, If something is wrong I don't want to see 100% Passed tests. Same goes to skipping the test if Excel is open that now show as "Inconclusive" in the summery.
Regarding #666 Skipping all AutoSize tests in Linux, I didn't see any problem with AutoSize on Linux, not sure why it was done, all tests are passing now on Linux to.
None of the tests are now skipped on Linux.
I was wandering why TestDrive: is not used well before the Linux support issue, I think it's a cleaner solution.
@dfinke Regarding your Docker enhancement request, do you think it's something that have a demand for? I didn't see people using modules form Docker. I'm going to check it out anyway as I didn't use Docker before and you piqued my interest (: