Skip to content

Commit

Permalink
tests: reproduce 1.2.8 bug in v2 to see if exists
Browse files Browse the repository at this point in the history
  • Loading branch information
levibostian committed Jan 6, 2023
1 parent 22f81b7 commit 877efd9
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions Tests/MessagingInApp/MessagingInAppIntegrationTest.swift
@@ -1,21 +1,20 @@
@testable import CioTracking
@testable import CioMessagingInApp
@testable import CioTracking
@testable import Common
import Foundation
import SharedTests
import XCTest

class MessagingInAppIntegrationTests: IntegrationTest {

// Reproduce bug: https://github.com/customerio/customerio-ios/issues/242
// Bug reported when: using in-app messaging, debug logging enabled, and using iOS version 1.2.8.
// Report: https://github.com/customerio/customerio-ios/issues/242
func test_initialize_enableDebugLogs_() {
CustomerIO.resetSharedInstance()

CustomerIO.initialize(siteId: testSiteId, apiKey: .random)
CustomerIO.config {
tearDown() // re-initialize with different configuration options.

CustomerIO.initialize(siteId: testSiteId, apiKey: .random, region: .EU) {
$0.logLevel = .debug
}
MessagingInApp.shared.initialize(organizationId: .random)

MessagingInApp.initialize(organizationId: .random) // would crash because DiGraph not initialized
}
}

0 comments on commit 877efd9

Please sign in to comment.