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

MBX-3712: Fix potentially fluky test #464

Merged
merged 1 commit into from
Nov 18, 2024
Merged

Conversation

justSmK
Copy link
Contributor

@justSmK justSmK commented Nov 18, 2024

На основании этого упавшего Action

MindboxTests.MBLoggerCoreDataManagerTests
test_measure_create_10_000, XCTAssertEqual failed: ("100488") is not equal to ("100000")
/Users/runner/work/ios-sdk/ios-sdk/MindboxTests/MindboxLogger/MBLoggerCoreDataManagerTests.swift:57

      let remainingLogs = try manager.fetchPeriod(Date.distantPast, Date.distantFuture)
      XCTAssertEqual(remainingLogs.count, logsCount * 10)
      XCTAssertEqual(remainingLogs.last?.message, "Log: 9999")

Возможно ему не хватает в какой-то момент времени удалить всё из БД, и поэтому попала часть данных в выборку всего, так как тест охватывал вообще все существующие даты try manager.fetchPeriod(Date.distantPast, Date.distantFuture). На локали ни разу такого не было. На CI вот в первый раз стрельнуло.

@justSmK justSmK merged commit 98ec625 into develop Nov 18, 2024
2 checks passed
@justSmK justSmK deleted the fix/MBX-3712-fix-test branch November 18, 2024 15: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.

1 participant