Skip to content

Commit b959769

Browse files
committed
fix tests
1 parent c31b0db commit b959769

7 files changed

Lines changed: 10 additions & 4 deletions

File tree

  • dev-packages
    • browser-integration-tests/suites/public-api/logger
    • node-core-integration-tests/suites
    • node-integration-tests/suites/public-api/logger
  • packages/core/src/logs

dev-packages/browser-integration-tests/suites/public-api/logger/integration/test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ sentryTest('should capture console object calls', async ({ getLocalTestUrl, page
2323
content_type: 'application/vnd.sentry.items.log+json',
2424
},
2525
{
26+
version: 2,
27+
ingest_settings: { infer_ip: 'never', infer_user_agent: 'never' },
2628
items: [
2729
{
2830
timestamp: expect.any(Number),

dev-packages/browser-integration-tests/suites/public-api/logger/scopeAttributes/test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ sentryTest('captures logs with scope attributes', async ({ getLocalTestUrl, page
2222
content_type: 'application/vnd.sentry.items.log+json',
2323
},
2424
{
25+
version: 2,
26+
ingest_settings: { infer_ip: 'never', infer_user_agent: 'never' },
2527
items: [
2628
{
2729
timestamp: expect.any(Number),

dev-packages/browser-integration-tests/suites/public-api/logger/simple/test.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ sentryTest('should capture all logging methods', async ({ getLocalTestUrl, page
2323
content_type: 'application/vnd.sentry.items.log+json',
2424
},
2525
{
26+
version: 2,
27+
ingest_settings: { infer_ip: 'never', infer_user_agent: 'never' },
2628
items: [
2729
{
2830
timestamp: expect.any(Number),

dev-packages/node-core-integration-tests/suites/light-mode/logs/test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ describe('light mode logs', () => {
1111
.expect({
1212
log: logsContainer => {
1313
expect(logsContainer).toEqual({
14+
version: 2,
1415
items: [
1516
{
1617
attributes: {

dev-packages/node-core-integration-tests/suites/public-api/logs/test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ describe('logger public API', () => {
1111
.expect({
1212
log: logsContainer => {
1313
expect(logsContainer).toEqual({
14+
version: 2,
1415
items: [
1516
{
1617
attributes: {

dev-packages/node-integration-tests/suites/public-api/logger/test.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ describe('logs', () => {
3939
.expect({
4040
log: logsContainer => {
4141
expect(logsContainer).toEqual({
42+
version: 2,
4243
items: [
4344
{
4445
timestamp: expect.any(Number),

packages/core/src/logs/envelope.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,7 @@ import { isBrowser } from '../utils/isBrowser';
1414
* Only emitted as `ingest_settings` in browser environments.
1515
* @returns The created log container envelope item.
1616
*/
17-
export function createLogContainerEnvelopeItem(
18-
items: Array<SerializedLog>,
19-
inferUserData?: boolean,
20-
): LogContainerItem {
17+
export function createLogContainerEnvelopeItem(items: Array<SerializedLog>, inferUserData?: boolean): LogContainerItem {
2118
const inferSetting = inferUserData ? 'auto' : 'never';
2219
return [
2320
{

0 commit comments

Comments
 (0)