Skip to content

Conversation

@hsubox76
Copy link
Contributor

@hsubox76 hsubox76 commented Oct 27, 2025

Remove src/methods/chrome-adapter.ts from all paths that would be reached by test:node.

yarn test:node tested locally

@changeset-bot
Copy link

changeset-bot bot commented Oct 27, 2025

⚠️ No Changeset found

Latest commit: 6f6302d

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@hsubox76 hsubox76 changed the title fix(ai): Fix node tests test(ai): Fix node tests Oct 27, 2025
)
new Component(
AI_TYPE,
factory ?? factoryNode,
Copy link
Contributor

Choose a reason for hiding this comment

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

I'm not sure if I understand this part correctly.

If no factory is provided, we default to the Node factory. Since no callers of getFullApp provide a factory, wouldn't all tests use the Node factory?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The only time getFullApp was used is in AI tests that use getAI(), and I assumed there were some hybrid/browser-specific ones that would need this, but it looks like there weren't. I think there should be (always good to have tests that are as e2e as possible) so I added two in api-browser.test.ts.

Copy link
Contributor

Choose a reason for hiding this comment

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

Sounds good.
Small nit: I think if we're defaulting to factoryNode, this should be done in the signature

factory?: InstanceFactory<'AI'> = factoryNode

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Oct 28, 2025

Size Report 1

Affected Products

  • @firebase/ai

    TypeBase (8209266)Merge (4df0052)Diff
    browser65.1 kB65.4 kB+240 B (+0.4%)
    main69.0 kB69.2 kB+240 B (+0.3%)
    module65.1 kB65.4 kB+240 B (+0.4%)
  • firebase

    TypeBase (8209266)Merge (4df0052)Diff
    firebase-ai.js51.3 kB51.4 kB+114 B (+0.2%)

Test Logs

  1. https://storage.googleapis.com/firebase-sdk-metric-reports/5o8nEV3rnP.html

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Oct 28, 2025

Size Analysis Report 1

Affected Products

  • @firebase/ai

    • LiveGenerativeModel

      Size

      TypeBase (8209266)Merge (4df0052)Diff
      size13.8 kB13.9 kB+120 B (+0.9%)
      size-with-ext-deps31.5 kB31.6 kB+120 B (+0.4%)
    • getLiveGenerativeModel

      Size

      TypeBase (8209266)Merge (4df0052)Diff
      size16.2 kB16.3 kB+120 B (+0.7%)
      size-with-ext-deps33.9 kB34.1 kB+120 B (+0.4%)

Test Logs

  1. https://storage.googleapis.com/firebase-sdk-metric-reports/USjbHYP2VL.html

@hsubox76 hsubox76 marked this pull request as ready for review October 28, 2025 17:22
@hsubox76 hsubox76 requested a review from a team as a code owner October 28, 2025 17:22
@@ -0,0 +1,48 @@
/**
* @license
* Copyright 2024 Google LLC
Copy link
Contributor

Choose a reason for hiding this comment

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

2025

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks, done.

)
new Component(
AI_TYPE,
factory ?? factoryNode,
Copy link
Contributor

Choose a reason for hiding this comment

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

Sounds good.
Small nit: I think if we're defaulting to factoryNode, this should be done in the signature

factory?: InstanceFactory<'AI'> = factoryNode

@hsubox76 hsubox76 merged commit 6e0e303 into main Oct 28, 2025
38 checks passed
@hsubox76 hsubox76 deleted the ch-hybrid-node-fix branch October 28, 2025 21:00
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.

4 participants