Skip to content
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

Update Copy-DbaAgentSchedule.Tests.ps1 with Integration Test #5487

Merged
merged 4 commits into from
May 9, 2019

Conversation

gbargsley
Copy link
Contributor

Type of Change

  • Bug fix (non-breaking change, fixes #)
  • New feature (non-breaking change, adds functionality)
  • Breaking change (effects multiple commands or functionality)
  • Ran manual Pester test and has passed (`.\tests\manual.pester.ps1)
  • Adding code coverage to existing functionality
  • Pester test is included
  • If new file reference added for test, has is been added to github.com/sqlcollaborative/appveyor-lab ?
  • Nunit test is included
  • Documentation
  • Build system

Purpose

Approach

Commands to test

Screenshots

Learning

@gbargsley
Copy link
Contributor Author

So Copy-DbaAgentSchedule copies all schedules and does not allow for a specific one to be copied. How can I determine if Instance 2 has any Agent Schedules so I know how many total their will be after I add my test.

@joshcorr
Copy link
Contributor

joshcorr commented May 8, 2019

Why not do a BeforeAll inside the Context block to gather the current number of Agent Schedules before running the copy in the test. That would ensure you know how many before moving. Or you could also write it to be Something like $results | Should Be Greaterthan 1

@potatoqualitee
Copy link
Member

Thanks much! It says fail but it's another test. Thanks so much, please keep em coming!

@potatoqualitee potatoqualitee merged commit 556ddb0 into development May 9, 2019
@potatoqualitee potatoqualitee deleted the IntTest-CopyDbaAgentSchedule branch May 9, 2019 08:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants