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

Restructure SDK #51

Open
wants to merge 29 commits into
base: main
Choose a base branch
from
Open

Restructure SDK #51

wants to merge 29 commits into from

Conversation

narekhovhannisyan
Copy link
Collaborator

@narekhovhannisyan narekhovhannisyan commented Aug 19, 2024

Motivation

  1. The general and testing APIs are created lazily, after the first access to the corresponding getters.
  2. Missing params for the Testing API (here) are treated as errors (throw new Error(...)), not warnings.
  3. Updated the MailtrapClient to accept two more params: bulk: Boolean and sandbox: Boolean. They are changing the behavior of the send method of the client in the following way:
let host

if (this.bulk && this.sandbox) {
  throw new Error('bulk mode is not applicable for sandbox API');
}
else if (this.sandbox) {
  host = TESTING_ENDPOINT; // should be sandbox.api.mailtrap.io
}
else if (this.bulk) {
  host = BULK_SENDING_ENDPOINT;
}
else {
  host = SENDING_ENDPOINT;
}

In the sandbox mode, the client.send sends the email to the sandbox, in the bulk mode - to the Bulk API.

  1. Removes send methods from the BulkSendingAPI and TestingAPI classes. There should be only one send method on the MailtrapClient that will behave as described above.

Summary by CodeRabbit

Release Notes

  • New Features

    • Introduced new configuration for CodeQL analysis to enhance code quality checks.
    • Added support for bulk email sending in the Mailtrap client.
    • New examples for sending emails using Mailtrap and Nodemailer.
  • Bug Fixes

    • Improved error handling for incompatible bulk and sandbox modes in the Mailtrap client.
    • Added a new error message for bulk mode incompatibility with the sandbox API.
  • Documentation

    • Updated the README for better clarity on version compatibility.
  • Tests

    • Enhanced test coverage for MailtrapClient with new scenarios.
    • Removed outdated tests related to bulk email functionality.


it("rejects with Mailtrap error, bulk and sanbox modes are incompatible.", async () => {
const client = new MailtrapClient({
token: "MY_API_TOKEN",

Check failure

Code scanning / CodeQL

Hard-coded credentials Critical test

The hard-coded value "MY_API_TOKEN" is used as
authorization header
.
Copy link
Contributor

Choose a reason for hiding this comment

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

Please use the recommended ways to disable the Code Scanning checks in tests


it("successfully sends testing email.", async () => {
const testingClient = new MailtrapClient({
token: "MY_API_TOKEN",

Check failure

Code scanning / CodeQL

Hard-coded credentials Critical test

The hard-coded value "MY_API_TOKEN" is used as
authorization header
.

it("successfully sends bulk email.", async () => {
const bulkClient = new MailtrapClient({
token: "MY_API_TOKEN",

Check failure

Code scanning / CodeQL

Hard-coded credentials Critical test

The hard-coded value "MY_API_TOKEN" is used as
authorization header
.

it("handles an API error.", async () => {
const testingClient = new MailtrapClient({
token: "MY_API_TOKEN",

Check failure

Code scanning / CodeQL

Hard-coded credentials Critical test

The hard-coded value "MY_API_TOKEN" is used as
authorization header
.

it("handles an HTTP transport error.", async () => {
const testingClient = new MailtrapClient({
token: "MY_API_TOKEN",

Check failure

Code scanning / CodeQL

Hard-coded credentials Critical test

The hard-coded value "MY_API_TOKEN" is used as
authorization header
.
expect.assertions(3);
it("rejects with Mailtrap error, when `testInboxId` is missing.", () => {
const client = new MailtrapClient({
token: "MY_API_TOKEN",

Check failure

Code scanning / CodeQL

Hard-coded credentials Critical test

The hard-coded value "MY_API_TOKEN" is used as
authorization header
.

it("returns testing API object, console warn is called twice.", () => {
const client = new MailtrapClient({
token: "MY_API_TOKEN",

Check failure

Code scanning / CodeQL

Hard-coded credentials Critical test

The hard-coded value "MY_API_TOKEN" is used as
authorization header
.
describe("get general(): ", () => {
it("returns testing API object, console warn is called twice.", () => {
const client = new MailtrapClient({
token: "MY_API_TOKEN",

Check failure

Code scanning / CodeQL

Hard-coded credentials Critical test

The hard-coded value "MY_API_TOKEN" is used as
authorization header
.
@narekhovhannisyan narekhovhannisyan marked this pull request as draft August 19, 2024 11:09
@narekhovhannisyan narekhovhannisyan marked this pull request as ready for review August 19, 2024 11:41
README.md Outdated Show resolved Hide resolved
examples/bulk/send-mail.ts Show resolved Hide resolved

it("rejects with Mailtrap error, bulk and sanbox modes are incompatible.", async () => {
const client = new MailtrapClient({
token: "MY_API_TOKEN",
Copy link
Contributor

Choose a reason for hiding this comment

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

Please use the recommended ways to disable the Code Scanning checks in tests

}
}
});

it("sends request to mailtrap api", async () => {
Copy link
Contributor

Choose a reason for hiding this comment

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

Since we have a bunch of tests dedicated to sending emails using Sending API's send method, I suggest grouping them under a describe. Probably, even like this:

describe("configuration errors", () => {
  it("rejects with Mailtrap error, bulk and sanbox modes are incompatible.", ...)
})
describe("using Testing API", () => {
  it("successfully sends testing email.", ...)
  it("handles an API error.", ...)
})
describe("using Sending API", () => {
  // all Sending API examples
})
describe("using Bulk API", () => {
  it("successfully sends email using the Bulk API.", ...)
  it("handles an API error.", ...)
})
describe("API endpoint objects", () => {
  // getXXXApi examples
})

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

they are under send method's describe section. At the moment we don't have multiple test cases for each API method. I guess we can introduce it later when we will deeply cover all the methods.

src/lib/MailtrapClient.ts Outdated Show resolved Hide resolved
@vittorius vittorius force-pushed the restructure-sdk branch 3 times, most recently from 7e1b802 to 52fcd1a Compare August 27, 2024 13:56
@@ -6,6 +6,9 @@ jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: github/codeql-action/init@v3
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

I guess since codeql is not triggered from the workflow, we don't have to mention it here.

@VladimirTaytor
Copy link
Contributor

@coderabbitai review

Copy link

coderabbitai bot commented Sep 18, 2024

Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Copy link

coderabbitai bot commented Sep 18, 2024

Walkthrough

The changes encompass the introduction and modification of various configuration files, examples, and tests within the project. A new CodeQL configuration file was added to streamline code analysis, while updates were made to the GitHub Actions workflow to integrate CodeQL analysis. The MailtrapClient class was enhanced with new parameters for bulk and sandbox modes, and several files were reorganized or created to demonstrate email functionality using Mailtrap. Additionally, tests were removed and added to improve coverage and error handling.

Changes

File Path Change Summary
.github/codeql/codeql-config.yml Added paths for analysis targeting src and ignored test files in src/__tests__.
.github/workflows/test.yml Added step to initialize CodeQL analysis using the new configuration file.
README.md Reorganized section on compatibility with previous releases for clarity.
examples/bulk/send-mail.ts Modified MailtrapClient instantiation to include bulk: true and changed sending method from client.bulk.send to client.send.
examples/bulk/transport.ts Introduced example for sending emails using Nodemailer with Mailtrap.
examples/general/*.ts Updated import statements for MailtrapClient from relative paths to direct package imports.
examples/sending/transport.ts Minor syntax fix in Nodemailer transport setup.
examples/testing/*.ts Updated import statements for MailtrapClient from relative paths to direct package imports; introduced examples for sending emails.
src/__tests__/lib/api/Bulk.test.ts Removed unit tests for BulkAPI class.
src/__tests__/lib/api/Testing.test.ts Removed tests for send() method in Testing class.
src/__tests__/lib/mailtrap-client.test.ts Enhanced tests for MailtrapClient, adding scenarios for error handling and successful email sending.
src/__tests__/lib/normalizer.test.ts Removed test for checking if the testing client is switched.
src/config/index.ts Added new error message for bulk and sandbox mode incompatibility.
src/lib/MailtrapClient.ts Updated constructor to accept bulk and sandbox parameters; introduced determineHost method for endpoint selection; improved error handling for missing parameters.
src/lib/api/Bulk.ts Removed BulkAPI class.
src/lib/api/Testing.ts Modified constructor to remove testInboxId; removed send method, limiting functionality.
src/lib/normalizer.ts Simplified normalizeCallback function by removing conditional logic for mailtrapClient.
src/types/mailtrap.ts Added optional bulk and sandbox properties to MailtrapClientConfig.
src/types/transport.ts Removed optional sandbox property from AdditionalFields type.

Suggested reviewers

  • coderabbitai
  • VladimirTaytor

Poem

🐇 In the garden of code, changes bloom bright,
With Mailtrap's magic, emails take flight.
New paths for testing, a workflow refined,
In the realm of the rabbit, great progress we find!
Hopping through updates, with joy we will cheer,
For every small change brings us closer, my dear! 🌼


Recent review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between eed53c6 and b03961e.

Files selected for processing (1)
  • examples/testing/transport.ts (1 hunks)
Files skipped from review as they are similar to previous changes (1)
  • examples/testing/transport.ts

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    -- I pushed a fix in commit <commit_id>, please review it.
    -- Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    -- @coderabbitai generate unit testing code for this file.
    -- @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    -- @coderabbitai generate interesting stats about this repository and render them as a table.
    -- @coderabbitai read src/utils.ts and generate unit testing code.
    -- @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    -- @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

Outside diff range and nitpick comments (3)
examples/bulk/send-mail.ts (1)

17-17: Consider adding a similar example for the sandbox: true flag usage.

As suggested in the past review comments, it would be great to add a similar example under the /examples/testing directory to illustrate the sandbox: true flag usage. This will provide a comprehensive set of examples for different use cases.

examples/testing/send-mail.ts (1)

1-25: LGTM!

The code provides a clear and concise example of how to send emails using the Mailtrap client. The comments and constants make it easy for users to understand and modify the code to suit their needs. The promise handling ensures that the success or error of the email sending operation is logged.

Here are a few suggestions to further improve the code:

  1. Consider adding error handling for the case where the required constants are not provided.
  2. Consider adding a comment to explain the purpose of the sandbox parameter in the MailtrapClient constructor.
  3. Consider adding a comment to explain the structure of the object passed to the send method.
examples/testing/transport.ts (1)

47-51: Consider removing the intentionally invalid HTML/CSS if not needed.

The comment suggests that the HTML/CSS in this segment is intentionally invalid for demonstration purposes. If this is not needed, consider removing it to avoid confusion.

Apply this diff to remove the invalid HTML/CSS:

-      <!-- Example of invalid for email html/css, will be detected by Mailtrap: -->
-      <style>
-        .main { background-color: white; }
-        a:hover { border-left-width: 1em; min-height: 2em; }
-      </style>
Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 8b6e896 and eed53c6.

Files selected for processing (26)
  • .github/codeql/codeql-config.yml (1 hunks)
  • .github/workflows/test.yml (1 hunks)
  • README.md (1 hunks)
  • examples/bulk/send-mail.ts (1 hunks)
  • examples/bulk/transport.ts (1 hunks)
  • examples/general/account-accesses.ts (1 hunks)
  • examples/general/accounts.ts (1 hunks)
  • examples/general/permissions.ts (1 hunks)
  • examples/sending/transport.ts (1 hunks)
  • examples/testing/attachments.ts (1 hunks)
  • examples/testing/inboxes.ts (1 hunks)
  • examples/testing/messages.ts (1 hunks)
  • examples/testing/send-mail.ts (1 hunks)
  • examples/testing/template.ts (1 hunks)
  • examples/testing/transport.ts (1 hunks)
  • src/tests/lib/api/Bulk.test.ts (0 hunks)
  • src/tests/lib/api/Testing.test.ts (0 hunks)
  • src/tests/lib/mailtrap-client.test.ts (4 hunks)
  • src/tests/lib/normalizer.test.ts (0 hunks)
  • src/config/index.ts (1 hunks)
  • src/lib/MailtrapClient.ts (3 hunks)
  • src/lib/api/Bulk.ts (0 hunks)
  • src/lib/api/Testing.ts (1 hunks)
  • src/lib/normalizer.ts (1 hunks)
  • src/types/mailtrap.ts (1 hunks)
  • src/types/transport.ts (0 hunks)
Files not reviewed due to no reviewable changes (5)
  • src/tests/lib/api/Bulk.test.ts
  • src/tests/lib/api/Testing.test.ts
  • src/tests/lib/normalizer.test.ts
  • src/lib/api/Bulk.ts
  • src/types/transport.ts
Files skipped from review due to trivial changes (9)
  • .github/codeql/codeql-config.yml
  • examples/general/account-accesses.ts
  • examples/general/accounts.ts
  • examples/general/permissions.ts
  • examples/sending/transport.ts
  • examples/testing/attachments.ts
  • examples/testing/inboxes.ts
  • examples/testing/messages.ts
  • examples/testing/template.ts
Additional context used
Biome
examples/testing/transport.ts

[error] 19-19: expected , but instead found sandbox

Remove sandbox

(parse)

LanguageTool
README.md

[style] ~124-~124: Consider using a different adverb to strengthen your wording.
Context: ...github.com/vchin). Package version 3 is a completely new package.

(COMPLETELY_ENTIRELY)

Additional comments not posted (29)
.github/workflows/test.yml (1)

9-11: LGTM! The CodeQL analysis step is correctly configured.

The addition of the CodeQL analysis step enhances the workflow by integrating static code analysis capabilities, allowing for improved code quality checks during the CI/CD process.

The configuration file located at ./.github/codeql/codeql-config.yml is correctly referenced to customize the CodeQL analysis process for the repository.

The past review comment suggesting that mentioning CodeQL may not be necessary is no longer valid. The current code segment is triggering CodeQL analysis from the workflow, so it is appropriate to include this step.

examples/bulk/send-mail.ts (2)

15-15: LGTM!

The addition of the bulk: true option to the MailtrapClient constructor aligns with the PR objective to update the client to accept new parameters for bulk and sandbox modes.


17-17: LGTM!

The change in the method call from client.bulk.send to client.send aligns with the PR objective to consolidate the send functionality into a single method within the MailtrapClient.

src/lib/api/Testing.ts (1)

21-21: Approve the constructor simplification.

The removal of the testInboxId parameter simplifies the instantiation of the TestingAPI class, which is a positive change. This aligns with the removal of the send method, as indicated in the AI-generated summary, which likely used the testInboxId.

Verify that any code that previously passed the testInboxId argument when creating an instance of TestingAPI has been updated to remove this parameter.

Run the following script to find any remaining usages of TestingAPI constructor with testInboxId argument:

Verification successful

Verification successful: TestingAPI constructor change correctly implemented

The removal of the testInboxId parameter from the TestingAPI constructor has been successfully implemented across the codebase. Our verification process found:

  • No instances of TestingAPI constructor being called with three or more arguments.
  • The only usage of the constructor (in src/lib/MailtrapClient.ts) uses two arguments, consistent with the updated signature.

This confirms that the simplification of the TestingAPI class instantiation has been properly applied, and no outdated usages remain.

Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Description: Verify that `TestingAPI` constructor is not being called with `testInboxId` argument.

# Test: Search for `TestingAPI` constructor usage with `testInboxId` argument. Expect: No results.
rg --type typescript $'new TestingAPI\(.*,.*,.*\)'

Length of output: 86


Script:

#!/bin/bash
# Description: Verify that `TestingAPI` constructor is not being called with `testInboxId` argument.

# Test 1: Search for `TestingAPI` constructor usage with three or more arguments using "ts" file type
echo "Test 1: Searching for TestingAPI constructor with 3+ arguments (ts file type)"
rg --type ts $'new TestingAPI\(.*,.*,.*\)'

# Test 2: Search for `TestingAPI` constructor usage with three or more arguments without specifying file type
echo "Test 2: Searching for TestingAPI constructor with 3+ arguments (no file type specified)"
rg $'new TestingAPI\(.*,.*,.*\)'

# Test 3: Search for general `TestingAPI` usage
echo "Test 3: Searching for general TestingAPI usage"
rg 'TestingAPI'

# Test 4: List all TypeScript files in the repository
echo "Test 4: Listing all TypeScript files"
fd -e ts -e tsx

Length of output: 3228

src/config/index.ts (1)

12-12: LGTM!

The addition of the BULK_SANDBOX_INCOMPATIBLE error message is a valuable improvement to the error handling and user guidance in the application. The message clearly communicates the incompatibility between bulk mode and the sandbox API, helping developers identify and handle such scenarios appropriately.

The message is concise, consistent with the existing naming convention, and does not introduce any breaking changes or compatibility issues.

src/types/mailtrap.ts (1)

67-68: LGTM! The addition of bulk and sandbox properties enhances the Mailtrap client's configuration options.

The inclusion of these optional boolean properties in the MailtrapClientConfig type provides more flexibility and control over the Mailtrap client's behavior:

  • The bulk property likely indicates whether bulk operations are enabled.
  • The sandbox property likely indicates whether the client should operate in a sandbox environment.

These changes may impact how users interact with the Mailtrap API, as they can now specify bulk and sandbox modes when configuring the client. The changes are backward compatible, as the properties are optional.

src/lib/normalizer.ts (1)

Line range hint 40-48: LGTM! The changes simplify the code and improve type safety.

The removal of the mailtrapClient variable and the direct usage of client for sending emails streamline the function's flow by eliminating unnecessary conditional logic. This simplification improves code readability and maintainability.

Additionally, the explicit typing of the error parameter as any in the .catch block enhances type safety in TypeScript, helping catch potential type-related issues.

examples/bulk/transport.ts (4)

1-13: LGTM!

The import statements and constants are correctly defined and used in the file.


15-18: LGTM!

The transport object is correctly created with the necessary options for bulk sending.


20-58: LGTM!

The email sending logic is correctly implemented with all the necessary components such as text, HTML, and an attachment. The HTML body is well-structured, and the attachment is correctly read from the file system.


59-60: LGTM!

The promise handling is correctly implemented using .then and .catch methods. Logging the success and error is useful for debugging and monitoring.

examples/testing/transport.ts (2)

22-61: LGTM!

The email sending logic is implemented correctly, and the code is well-structured.


61-62: LGTM!

The promise handling logic is implemented correctly.

src/lib/MailtrapClient.ts (6)

15-15: LGTM!

The import statement for MailtrapError is added correctly. It will likely be used for improved error handling in the code changes below.


18-27: LGTM!

The constants are added correctly by destructuring the CLIENT_SETTINGS and ERRORS objects. They will likely be used in the code changes below.


39-41: LGTM!

The bulk and sandbox properties are added correctly to the MailtrapClient class. They will likely be used to configure the behavior of the MailtrapClient instance.


Line range hint 46-97: LGTM!

The constructor is updated correctly to accept the new bulk and sandbox parameters, and the corresponding properties are initialized correctly.

The error handling in the testing getter is improved by throwing MailtrapError instead of logging warnings, using the correct error messages from the ERRORS object.


99-117: LGTM!

The determineHost method is implemented correctly:

  • It checks for the incompatible combination of bulk and sandbox modes and throws a MailtrapError with the correct error message.
  • It determines the correct host URL based on the bulk and sandbox properties.
  • It's marked as private, which is appropriate since it's an internal implementation detail.

124-127: LGTM!

The send method is updated correctly to use the new determineHost method to determine the host URL, which is then correctly interpolated into the url variable.

README.md (1)

121-124: The existing comment by leonid-shevtsov is still valid and applicable to the current changes. Moving this section to the end of the README would be more appropriate as it is no longer news.

Tools
LanguageTool

[style] ~124-~124: Consider using a different adverb to strengthen your wording.
Context: ...github.com/vchin). Package version 3 is a completely new package.

(COMPLETELY_ENTIRELY)

src/__tests__/lib/mailtrap-client.test.ts (9)

44-56: LGTM!

The test case correctly verifies that the send method rejects with a MailtrapError when both bulk and sandbox modes are set to true.


59-93: LGTM!

The test case correctly verifies that the send method successfully sends a testing email when sandbox mode is set to true and a valid testInboxId is provided.


95-128: LGTM!

The test case correctly verifies that the send method successfully sends a bulk email when bulk mode is set to true.


130-175: LGTM!

The test case correctly verifies that the send method handles an API error correctly when the API returns a 400 response with an error message.


177-212: LGTM!

The test case correctly verifies that the send method handles an HTTP transport error correctly when the API returns a 404 response.


333-344: LGTM!

The test case correctly verifies that the testing getter rejects with a MailtrapError when testInboxId is missing.


347-360: LGTM!

The test case correctly verifies that the testing getter rejects with a MailtrapError when accountId is missing.


362-373: LGTM!

The test case correctly verifies that the testing getter returns a TestingAPI instance when both testInboxId and accountId are provided.


376-384: LGTM!

The test case correctly verifies that the general getter returns a GeneralAPI instance.

const transport = Nodemailer.createTransport(MailtrapTransport({
token: TOKEN,
testInboxId: TEST_INBOX_ID
sandbox: true
Copy link

Choose a reason for hiding this comment

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

Fix the syntax error.

There is a missing comma after the testInboxId property.

Apply this diff to fix the syntax error:

-  testInboxId: TEST_INBOX_ID
+  testInboxId: TEST_INBOX_ID,
   sandbox: true
Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
sandbox: true
testInboxId: TEST_INBOX_ID,
sandbox: true
Tools
Biome

[error] 19-19: expected , but instead found sandbox

Remove sandbox

(parse)

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