-
-
Notifications
You must be signed in to change notification settings - Fork 814
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
ConvertTo-DbaDataTable handle Dataplat.Dbatools.Utility.DbaDateTime as an array #9361
Conversation
Ok I wondered how this was working because it wasn't working for me locally either - I've changed this to make sense (in my mind) and also updated the null one |
oh sweet, we ready? thank you so much! i cant publish till i get home bc of the hardware key but happy to prep with a merge. |
re-read and indeed. thanks again 🙇🏼 |
okay that's weird, we have a test that passed but then when it merged, it failed?
|
I skipped it in dev since its causing all of our branches to fail |
Hey @potatoqualitee - I'm in Lisbon to see Taylor swift tonight 😂 but I'll take a look at this! It did pass locally and on the branch before merge 🤔 |
HEYYY enjoy taylor swift!!! we can look at this later 😊 |
I created a new branch off develoment and removed the https://github.com/dataplat/dbatools/tree/testingtests https://ci.appveyor.com/project/dataplat/dbatools/builds/49936347 Is it worth uncommenting in development and seeing what happens? If not we can maybe troubleshoot and fix forward? Honestly it's kind of a weird test anyway - we already test string values get converted ok - so I'm not sure what this is adding. Context "Property: myObject" {
It 'Has a column called "myObject"' {
$result.Columns.ColumnName | Should -Contain 'myObject'
}
It 'Has a [string] data type on the column "myObject"' {
$result.myObject | Should -BeOfType [System.String]
}
} |
@jpomfret beautiful! and pfewf. So no change needed to the command, eh? Please do feel free to create a PR and I'll merge with the next batch. |
so @potatoqualitee ... when I went to PR the test was still skipped 🤦 let me try this again - please hold 😂😂 |
This is so interesting - this test works completely different in appveyor vs locally @wsmelton - remember this test - neither of us knew how it was passing in appveyor - I changed it to what was passing locally - and now it's failing in appveyor 😖 Shall I remove this test? or change it back to testing for null? |
lemme test "on my rig" and get back. |
lol thanks niph, i had no idea how to make it pass |
yeah. beware that we have another problem, I don't know why "scenario 2008R2, part=1/2" for 2 weeks roughly is sooo borked that it fails badly an the "thingy" that reports back if something fails doesn't know what to read. It seems a pester 5 dependency has slipped in. https://ci.appveyor.com/project/dataplat/dbatools/builds/49958879/job/0386qjwfw6ofci83 , in particular https://ci.appveyor.com/project/dataplat/dbatools/builds/49958879/job/0386qjwfw6ofci83/tests and I don't know how to fix it but we may try to alter appveyor.yml on development to let it clear and re-cache dependencies, as most of them are linked to the content of appveyor.yml itself . |
tried my best, AND added some debug prints to uncover the "problem" , see https://ci.appveyor.com/project/dataplat/dbatools/build/job/68qbb1hlj9p98v9w specifically, I think there might be some "strange happenings" around the fact that:
That being said, bumping appveyor.yml did fix the weird issue of a rogue pester 5 in the cache, and I modified:
|
Thanks @niphlod for trying - so what do we think for this test, are we thinking it's not really testing what we want? Shall I remove that piece? 🤔 |
pragmatically ..... something is going awry so if it's the one test causing problems (and, btw, it seems unrelated to serializing succesfully dbadatetime[]) so you may choose to just forget about it. |
/cc @jpomfret This failed and I'm not sure how I thought it passed in the branch?
Hmm @niphlod - can you check this failure for me? On the firstRow stuff you added in: |
sure @jpomfret , lemme revert all the "debug" prints, it was just to illustrate that the test fail(ed) because, indeed, that property was null in the first place. |
done, it should pass now (and not spit a blob of magenta lines). |
Thank you 👏 |
BTW, to fix this I'll open another PR (end of day, I promise).
They were within the changes I pushed on this branch but they got reverted... better keep this PR "on point" and a separate one will make things better for everyone on the testing side. |
I stand corrected, #9384 has everything in. |
Type of Change
.\tests\manual.pester.ps1
)Commands to test