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

Add getCurrentSpeech() function & tests #71

Merged
merged 5 commits into from
Jun 4, 2018
Merged

Add getCurrentSpeech() function & tests #71

merged 5 commits into from
Jun 4, 2018

Conversation

desko27
Copy link
Contributor

@desko27 desko27 commented May 30, 2018

No description provided.

@zhouzi
Copy link
Owner

zhouzi commented Jun 1, 2018

@desko27 Thank you so much for contributing and taking the time to add documentation and tests! 👍 I am wondering what is the expected behavior for the following use case:

theater
  .addActor('vader')
  .addScene('vader:Luke...')
  .on('erase:start', function () {
    console.log(theater.getCurrentSpeech())
  })

The erase scene doesn't have the speech in its arguments so it will log undefined. Is that what is expected? If so, it'd be great to have a test case covering that.

@desko27
Copy link
Contributor Author

desko27 commented Jun 3, 2018

@zhouzi You're totally right! Added null test case and reorganized getCurrentSpeech()'s code to make it simpler.

Thanks for this amazing library 👍🏻

@zhouzi zhouzi merged commit 6f30a8c into zhouzi:master Jun 4, 2018
@zhouzi
Copy link
Owner

zhouzi commented Jun 4, 2018

Thank you @desko27 👍

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.

2 participants