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

fix for #177 #192

Closed
wants to merge 1 commit into from
Closed

Conversation

Juravenator
Copy link

This implements a variation of the fix for #177 made by @Desproposito

@keanulee
Copy link
Contributor

Thanks for the fix @Juravenator . Can you add a test so that we don't regress this?

@Juravenator
Copy link
Author

I've been playing with the testing code to simulate a dragging gesture, but I can't seem to get it working.
I added an extra slider, since the test requires an initial value to be set using an attribute, and only an attribute.

<test-fixture id="customSlider">
    <template>
      <paper-slider value="50"></paper-slider>
    </template>
  </test-fixture>

I tried this approach to simulate a drag:

test('value doesn\'t max out on drag when initial value set', function() {
  // var node = customSlider.root.querySelector("paper-progress");
  var xy_middle = MockInteractions.middleOfNode(customSlider);
  // xy_middle.x += 10;
  // xy_middle.y += 10;
  var xy_end = {
    x: 0,
    y: xy_middle.y
  }
  MockInteractions.move(customSlider, xy_middle, xy_end);
});

As you can see, I tried modifying the paper-slider as well as the internal paper-progress that seems to be spawning the real events (observed using MonitorEvents($0) in chrome).

I seem to be missing something to make this work. Any suggestions?

@keanulee
Copy link
Contributor

Bug fixed by #194

@keanulee keanulee closed this Jun 13, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants