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

Implement Conditional New Tab in Mujo Extension #270

Closed

Conversation

Temmyogunbo
Copy link
Collaborator

@Temmyogunbo Temmyogunbo commented Oct 23, 2019

#137 Description
This PR implements a conditional new tab. Some tests are currently failing. Here's a snapshot below:
Screenshot 2019-10-27 at 2 27 32 AM

@Temmyogunbo Temmyogunbo added the help wanted Extra attention is needed label Oct 23, 2019
@jcblw
Copy link
Member

jcblw commented Oct 23, 2019

@Temmyogunbo can you add the better title to this pr that denotes what you are fixing vs. which ticket it closes. 🙏

Copy link
Member

@jcblw jcblw left a comment

Choose a reason for hiding this comment

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

We are not going to implement Google storage for this, and you use the existing storage system.

@jcblw
Copy link
Member

jcblw commented Oct 23, 2019

Also with this, we will need to implement a setting for this that the user can toggle in the setting panel. Open to not making an internal plugin for this, but I think it might be good to dog food the new system.

Here is an example of settings component.

test('conditional new tab', async () => {
onConditionalNewTab(NEW_TAB)

expect(storage.sync.get).toBeCalled()
Copy link
Member

Choose a reason for hiding this comment

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

I would like to test that tab update is being called if the setting is true and not called if the setting is off.

@jcblw
Copy link
Member

jcblw commented Oct 23, 2019

Lets chat more about this tomorrow. Over-all looks great, just a few things I think we should move around.

@Temmyogunbo Temmyogunbo changed the title Closes #236 Implement Conditional New Tab in Mujo Extension Oct 23, 2019
@Temmyogunbo Temmyogunbo force-pushed the fix/conditional-new-tab-page branch 2 times, most recently from 0f93979 to 934579c Compare October 27, 2019 01:28
@jcblw
Copy link
Member

jcblw commented Oct 27, 2019

@Temmyogunbo do you know if puppeteer is working at all for you?

@jcblw
Copy link
Member

jcblw commented Oct 27, 2019

It seems like it is not, but also I only am seeing a small amount of the tests

@jcblw
Copy link
Member

jcblw commented Oct 27, 2019

Ok so it looks like there may be some issues on how puppeteer is creating the new page, it does not seem to trigger the tabs.onCreate method. Looking into their library a little bit more to get some resolution. Also, not sure why the other test is failing it seems like that should be fine, and with the tabs.onCreate in the mock you should not need to overwrite it anymore.

@jcblw
Copy link
Member

jcblw commented Oct 27, 2019

I think we might need to open an issue on Puppeteer for this, seems like it might not be triggering that event :/

@jcblw
Copy link
Member

jcblw commented Oct 27, 2019

@Temmyogunbo opened an issue for this

puppeteer/puppeteer#5091

@jcblw jcblw mentioned this pull request Dec 23, 2019
@jcblw jcblw closed this Dec 23, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
help wanted Extra attention is needed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants