Skip to content
This repository has been archived by the owner on Dec 8, 2022. It is now read-only.

Added test utility from SKY UX #382

Merged
merged 3 commits into from
Mar 29, 2018
Merged

Added test utility from SKY UX #382

merged 3 commits into from
Mar 29, 2018

Conversation

Blackbaud-SteveBrush
Copy link
Member

No description provided.

@codecov-io
Copy link

codecov-io commented Mar 28, 2018

Codecov Report

Merging #382 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #382   +/-   ##
=======================================
  Coverage   99.25%   99.25%           
=======================================
  Files          71       71           
  Lines        1741     1741           
  Branches      283      283           
=======================================
  Hits         1728     1728           
  Misses         13       13
Flag Coverage Δ
#builder 100% <ø> (ø) ⬆️
#runtime 94.75% <ø> (ø) ⬆️
#srcapp 100% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4688d33...fb32659. Read the comment docs.

@@ -0,0 +1,23 @@
export interface SkyAppTestUtilityEventArgs {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think I'd call this SkyAppTestUtilityEventOptions instead. Ending a class name with EventArgs is a common pattern for classes used to pass arguments into an event handler, which is not the case here. I'd also move it to a separate file so we're only exporting one type from this file.

public static fireDomEvent(
element: EventTarget,
eventName: string,
args?: SkyAppTestUtilityEventArgs

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remember to change this parameter name to match the new class name.

cancelable?: boolean;
}

function getWindow() {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure I understand the purpose of this function. I could see if maybe you wanted to mock out the window object you'd want to do something like this, but it's not possible with the code as it is.

@Blackbaud-PaulCrowder Blackbaud-PaulCrowder merged commit 52827a0 into master Mar 29, 2018
@Blackbaud-SteveBrush Blackbaud-SteveBrush deleted the test-utility branch March 30, 2018 13:54
Blackbaud-MikitaYankouski pushed a commit to Blackbaud-MikitaYankouski/skyux-builder that referenced this pull request May 3, 2019
* Added test utility from SKY UX

* Separated event options into separate file
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants