forked from mozilla-mobile/firefox-ios
-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathswiftlint_baseline.json
More file actions
1 lines (1 loc) · 35.2 KB
/
Copy pathswiftlint_baseline.json
File metadata and controls
1 lines (1 loc) · 35.2 KB
1
[{"violation":{"reason":"Header comments should be consistent with project patterns","ruleIdentifier":"file_header","severity":"warning","ruleDescription":"Header comments should be consistent with project patterns. The SWIFTLINT_CURRENT_FILENAME placeholder can optionally be used in the required and forbidden patterns. It will be replaced by the real file name.","location":{"line":1,"character":1,"file":"firefox-ios\/Client\/AdjustHelper.swift"},"ruleName":"File Header"},"text":""},{"violation":{"ruleDescription":"Header comments should be consistent with project patterns. The SWIFTLINT_CURRENT_FILENAME placeholder can optionally be used in the required and forbidden patterns. It will be replaced by the real file name.","severity":"warning","ruleName":"File Header","location":{"file":"firefox-ios\/Client\/AdjustTelemetryHelper.swift","line":1,"character":1},"reason":"Header comments should be consistent with project patterns","ruleIdentifier":"file_header"},"text":""},{"violation":{"severity":"warning","ruleIdentifier":"vertical_parameter_alignment","reason":"Function parameters should be aligned vertically if they're in multiple lines in a declaration","ruleDescription":"Function parameters should be aligned vertically if they're in multiple lines in a declaration","ruleName":"Vertical Parameter Alignment","location":{"file":"firefox-ios\/Client\/Frontend\/Browser\/BrowserViewController\/State\/BrowserViewControllerState.swift","line":696,"character":47}},"text":" action: GeneralBrowserAction) -> BrowserViewControllerState {"},{"violation":{"ruleName":"Function Body Length","ruleDescription":"Function bodies should not span too many lines","reason":"Function body should span 122 lines or less excluding comments and whitespace: currently spans 130 lines","location":{"character":13,"file":"firefox-ios\/Client\/Frontend\/Home\/Homepage\/HomepageViewController.swift","line":599},"severity":"error","ruleIdentifier":"function_body_length"},"text":" private func configureCell("},{"violation":{"ruleIdentifier":"function_body_length","severity":"error","location":{"character":5,"line":15,"file":"firefox-ios\/Client\/Helpers\/MenuBuilderHelper.swift"},"reason":"Function body should span 122 lines or less excluding comments and whitespace: currently spans 242 lines","ruleName":"Function Body Length","ruleDescription":"Function bodies should not span too many lines"},"text":" func mainMenu(for builder: UIMenuBuilder) {"},{"violation":{"ruleName":"Force Cast","ruleIdentifier":"force_cast","severity":"error","location":{"line":70,"file":"firefox-ios\/Client\/Helpers\/MenuBuilderHelper.swift","character":17},"ruleDescription":"Force casts should be avoided","reason":"Force casts should be avoided"},"text":" ($0 as! UIKeyCommand).wantsPriorityOverSystemBehavior = true"},{"violation":{"severity":"error","ruleDescription":"Force casts should be avoided","ruleIdentifier":"force_cast","ruleName":"Force Cast","location":{"line":93,"file":"firefox-ios\/Client\/Helpers\/MenuBuilderHelper.swift","character":17},"reason":"Force casts should be avoided"},"text":" ($0 as! UIKeyCommand).wantsPriorityOverSystemBehavior = true"},{"violation":{"ruleIdentifier":"force_cast","reason":"Force casts should be avoided","ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","severity":"error","location":{"file":"firefox-ios\/Client\/Helpers\/MenuBuilderHelper.swift","character":17,"line":140}},"text":" ($0 as! UIKeyCommand).wantsPriorityOverSystemBehavior = true"},{"violation":{"ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","reason":"Force casts should be avoided","severity":"error","location":{"file":"firefox-ios\/Client\/Helpers\/MenuBuilderHelper.swift","character":21,"line":258}},"text":" ($0 as! UIKeyCommand).wantsPriorityOverSystemBehavior = true"},{"violation":{"ruleDescription":"Header comments should be consistent with project patterns. The SWIFTLINT_CURRENT_FILENAME placeholder can optionally be used in the required and forbidden patterns. It will be replaced by the real file name.","ruleIdentifier":"file_header","severity":"warning","reason":"Header comments should be consistent with project patterns","location":{"file":"firefox-ios\/Tuist.swift","character":1,"line":1},"ruleName":"File Header"},"text":""},{"violation":{"reason":"Force casts should be avoided","ruleIdentifier":"force_cast","ruleName":"Force Cast","location":{"line":710,"character":64,"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/Coordinators\/BrowserCoordinatorTests.swift"},"ruleDescription":"Force casts should be avoided","severity":"error"},"text":" let settingsCoordinator = subject.childCoordinators[0] as! SettingsCoordinator"},{"violation":{"ruleDescription":"Force casts should be avoided","location":{"character":59,"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/Coordinators\/BrowserCoordinatorTests.swift","line":733},"reason":"Force casts should be avoided","ruleName":"Force Cast","ruleIdentifier":"force_cast","severity":"error"},"text":" let etpCoordinator = subject.childCoordinators[0] as! EnhancedTrackingProtectionCoordinator"},{"violation":{"ruleName":"Force Cast","ruleDescription":"Force casts should be avoided","ruleIdentifier":"force_cast","severity":"error","location":{"line":791,"character":78,"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/Coordinators\/BrowserCoordinatorTests.swift"},"reason":"Force casts should be avoided"},"text":" let windowManager = (AppContainer.shared.resolve() as WindowManager) as! MockWindowManager"},{"violation":{"ruleIdentifier":"force_cast","severity":"error","reason":"Force casts should be avoided","ruleName":"Force Cast","location":{"character":64,"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/Coordinators\/BrowserCoordinatorTests.swift","line":952},"ruleDescription":"Force casts should be avoided"},"text":" let fakespotCoordinator = subject.childCoordinators[0] as! FakespotCoordinator"},{"violation":{"severity":"warning","location":{"character":1,"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/Helpers\/AdjustTelemetryHelperTests.swift","line":1},"reason":"Header comments should be consistent with project patterns","ruleIdentifier":"file_header","ruleName":"File Header","ruleDescription":"Header comments should be consistent with project patterns. The SWIFTLINT_CURRENT_FILENAME placeholder can optionally be used in the required and forbidden patterns. It will be replaced by the real file name."},"text":""},{"violation":{"ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/Mocks\/MockTests\/MockUserDefaultsTests.swift","line":37,"character":43},"reason":"Force casts should be avoided","severity":"error"},"text":" XCTAssertEqual(sut.savedData[key] as! Date, date)"},{"violation":{"ruleName":"Force Cast","severity":"error","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/Mocks\/MockTests\/MockUserDefaultsTests.swift","character":52,"line":45},"reason":"Force casts should be avoided","ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided"},"text":" let actualObject = sut.object(forKey: key) as! Date"},{"violation":{"ruleIdentifier":"force_cast","severity":"error","ruleName":"Force Cast","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/PrefsTests.swift","line":83,"character":54},"ruleDescription":"Force casts should be avoided","reason":"Force casts should be avoided"},"text":" let prefs = MockProfilePrefs().branch(\"baz\") as! MockProfilePrefs"},{"violation":{"reason":"Force casts should be avoided","ruleName":"Force Cast","ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided","severity":"error","location":{"character":57,"line":86,"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/PrefsTests.swift"}},"text":" XCTAssertEqual(val, (prefs.things[\"baz.foobar\"] as! NSNumber).uint64Value)"},{"violation":{"ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","reason":"Force casts should be avoided","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/PrefsTests.swift","character":55,"line":90},"ruleIdentifier":"force_cast","severity":"error"},"text":" let prefs1 = MockProfilePrefs().branch(\"bar\") as! MockProfilePrefs"},{"violation":{"ruleIdentifier":"force_cast","reason":"Force casts should be avoided","location":{"line":91,"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/PrefsTests.swift","character":55},"ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","severity":"error"},"text":" let prefs2 = MockProfilePrefs().branch(\"baz\") as! MockProfilePrefs"},{"violation":{"reason":"Functions and methods parameters should be either on the same line, or one per line","ruleDescription":"Functions and methods parameters should be either on the same line, or one per line","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/TestHistory.swift","character":22,"line":410},"ruleIdentifier":"multiline_parameters","severity":"warning","ruleName":"Multiline Parameters"},"text":" fileprivate func runMultiRandom("},{"violation":{"ruleName":"Force Cast","reason":"Force casts should be avoided","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/Wallpaper\/WallpaperNetworkingModuleTests.swift","character":34,"line":62},"ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided","severity":"error"},"text":" XCTAssertEqual(error as! URLError,"},{"violation":{"ruleDescription":"Force casts should be avoided","location":{"character":34,"line":78,"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/Wallpaper\/WallpaperNetworkingModuleTests.swift"},"reason":"Force casts should be avoided","severity":"error","ruleName":"Force Cast","ruleIdentifier":"force_cast"},"text":" XCTAssertEqual(error as! URLError,"},{"violation":{"ruleName":"Force Cast","severity":"error","reason":"Force casts should be avoided","ruleIdentifier":"force_cast","location":{"line":110,"file":"firefox-ios\/firefox-ios-tests\/Tests\/ClientTests\/Wallpaper\/WallpaperNetworkingModuleTests.swift","character":34},"ruleDescription":"Force casts should be avoided"},"text":" XCTAssertEqual(error as! WallpaperServiceError,"},{"violation":{"ruleDescription":"Function bodies should not span too many lines","ruleName":"Function Body Length","severity":"error","location":{"line":38,"file":"firefox-ios\/firefox-ios-tests\/Tests\/StorageTests\/RustPlacesTests.swift","character":5},"reason":"Function body should span 122 lines or less excluding comments and whitespace: currently spans 210 lines","ruleIdentifier":"function_body_length"},"text":" func testHistoryMetadataBasics() {"},{"violation":{"ruleName":"Force Cast","reason":"Force casts should be avoided","ruleDescription":"Force casts should be avoided","ruleIdentifier":"force_cast","severity":"error","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/StorageTests\/StorageTestUtils.swift","character":27,"line":63}},"text":" return row[0] as! GUID"},{"violation":{"severity":"error","reason":"Force casts should be avoided","ruleIdentifier":"force_cast","location":{"line":76,"character":33,"file":"firefox-ios\/firefox-ios-tests\/Tests\/StorageTests\/StorageTestUtils.swift"},"ruleDescription":"Force casts should be avoided","ruleName":"Force Cast"},"text":" return ($0[\"child\"] as! GUID, $0[\"idx\"] as! Int)"},{"violation":{"reason":"Force casts should be avoided","severity":"error","ruleDescription":"Force casts should be avoided","ruleIdentifier":"force_cast","location":{"character":53,"file":"firefox-ios\/firefox-ios-tests\/Tests\/StorageTests\/StorageTestUtils.swift","line":76},"ruleName":"Force Cast"},"text":" return ($0[\"child\"] as! GUID, $0[\"idx\"] as! Int)"},{"violation":{"ruleIdentifier":"force_cast","reason":"Force casts should be avoided","ruleName":"Force Cast","severity":"error","location":{"character":21,"file":"firefox-ios\/firefox-ios-tests\/Tests\/StorageTests\/TestBrowserDB.swift","line":57},"ruleDescription":"Force casts should be avoided"},"text":" (row[0] as! String, row[1] as! String)"},{"violation":{"ruleDescription":"Force casts should be avoided","ruleIdentifier":"force_cast","severity":"error","reason":"Force casts should be avoided","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/StorageTests\/TestBrowserDB.swift","line":57,"character":40},"ruleName":"Force Cast"},"text":" (row[0] as! String, row[1] as! String)"},{"violation":{"ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","severity":"error","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/StorageTests\/TestBrowserDB.swift","line":82,"character":71},"reason":"Force casts should be avoided"},"text":" let creationA = shmAAttributes[FileAttributeKey.creationDate] as! Date"},{"violation":{"reason":"Force casts should be avoided","severity":"error","location":{"line":83,"character":73,"file":"firefox-ios\/firefox-ios-tests\/Tests\/StorageTests\/TestBrowserDB.swift"},"ruleIdentifier":"force_cast","ruleName":"Force Cast","ruleDescription":"Force casts should be avoided"},"text":" let inodeA = (shmAAttributes[FileAttributeKey.systemFileNumber] as! NSNumber).uintValue"},{"violation":{"severity":"error","reason":"Force casts should be avoided","ruleDescription":"Force casts should be avoided","location":{"line":116,"file":"firefox-ios\/firefox-ios-tests\/Tests\/StorageTests\/TestBrowserDB.swift","character":71},"ruleIdentifier":"force_cast","ruleName":"Force Cast"},"text":" let creationB = shmBAttributes[FileAttributeKey.creationDate] as! Date"},{"violation":{"ruleName":"Force Cast","reason":"Force casts should be avoided","location":{"character":73,"line":117,"file":"firefox-ios\/firefox-ios-tests\/Tests\/StorageTests\/TestBrowserDB.swift"},"severity":"error","ruleDescription":"Force casts should be avoided","ruleIdentifier":"force_cast"},"text":" let inodeB = (shmBAttributes[FileAttributeKey.systemFileNumber] as! NSNumber).uintValue"},{"violation":{"ruleName":"Force Cast","ruleDescription":"Force casts should be avoided","ruleIdentifier":"force_cast","severity":"error","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/ClipBoardTests.swift","line":39,"character":95},"reason":"Force casts should be avoided"},"text":" var value = app.textFields[AccessibilityIdentifiers.Browser.UrlBar.url].value as! String"},{"violation":{"location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift","character":51,"line":132},"ruleDescription":"Force casts should be avoided","reason":"Force casts should be avoided","ruleIdentifier":"force_cast","severity":"error","ruleName":"Force Cast"},"text":" if saveAndFillPaymentMethodsSwitch.value! as! String == \"1\" {"},{"violation":{"location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift","character":63,"line":135},"reason":"Force casts should be avoided","severity":"error","ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided","ruleName":"Force Cast"},"text":" XCTAssertEqual(saveAndFillPaymentMethodsSwitch.value! as! String, \"0\")"},{"violation":{"reason":"Force casts should be avoided","ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","ruleIdentifier":"force_cast","location":{"line":158,"character":67,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift"},"severity":"error"},"text":" XCTAssertEqual(saveAndFillPaymentMethodsSwitch.value! as! String, \"1\")"},{"violation":{"severity":"error","location":{"character":58,"line":184,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift"},"ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","reason":"Force casts should be avoided"},"text":" XCTAssertEqual(contentView[\"Card number\"].value! as! String, \"2720 9943 2658 1252\")"},{"violation":{"reason":"Force casts should be avoided","ruleIdentifier":"force_cast","ruleName":"Force Cast","ruleDescription":"Force casts should be avoided","severity":"error","location":{"line":185,"character":57,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift"}},"text":" XCTAssertEqual(contentView[\"Expiration\"].value! as! String, \"05 \/ 40\")"},{"violation":{"severity":"error","location":{"character":64,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift","line":186},"reason":"Force casts should be avoided","ruleName":"Force Cast","ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided"},"text":" XCTAssertEqual(contentView[\"Full name on card\"].value! as! String, \"Test\")"},{"violation":{"location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift","line":187,"character":50},"severity":"error","ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","reason":"Force casts should be avoided","ruleIdentifier":"force_cast"},"text":" XCTAssertEqual(contentView[\"CVC\"].value! as! String, \"CVC\")"},{"violation":{"location":{"character":50,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift","line":188},"reason":"Force casts should be avoided","severity":"error","ruleName":"Force Cast","ruleDescription":"Force casts should be avoided","ruleIdentifier":"force_cast"},"text":" XCTAssertEqual(contentView[\"ZIP\"].value! as! String, \"ZIP\")"},{"violation":{"ruleDescription":"Functions and methods parameters should be either on the same line, or one per line","severity":"warning","reason":"Functions and methods parameters should be either on the same line, or one per line","location":{"line":510,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift","character":18},"ruleIdentifier":"multiline_parameters","ruleName":"Multiline Parameters"},"text":" private func fillCardDetailsOnWebsite(cardNr: String, expirationDate: String, nameOnCard: String,"},{"violation":{"ruleIdentifier":"force_cast","severity":"error","location":{"line":620,"character":58,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift"},"ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","reason":"Force casts should be avoided"},"text":" XCTAssertEqual(contentView[\"Card number\"].value! as! String, cardNr)"},{"text":" XCTAssertEqual(contentView[\"Expiration\"].value! as! String, expirationNr)","violation":{"ruleIdentifier":"force_cast","location":{"line":621,"character":57,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift"},"ruleName":"Force Cast","severity":"error","ruleDescription":"Force casts should be avoided","reason":"Force casts should be avoided"}},{"text":" XCTAssertEqual(contentView[\"Full name on card\"].value! as! String, name)","violation":{"severity":"error","ruleName":"Force Cast","ruleDescription":"Force casts should be avoided","ruleIdentifier":"force_cast","reason":"Force casts should be avoided","location":{"line":622,"character":64,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift"}}},{"text":" XCTAssertEqual(contentView[\"CVC\"].value! as! String, \"CVC\")","violation":{"reason":"Force casts should be avoided","ruleName":"Force Cast","ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided","severity":"error","location":{"line":623,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift","character":50}}},{"text":" XCTAssertEqual(contentView[\"ZIP\"].value! as! String, \"ZIP\")","violation":{"ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","ruleIdentifier":"force_cast","severity":"error","reason":"Force casts should be avoided","location":{"line":624,"character":50,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift"}}},{"text":" if saveAndFillPaymentMethodsSwitch.value! as! String == \"0\" {","violation":{"ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","location":{"line":652,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/CreditCardsTests.swift","character":51},"reason":"Force casts should be avoided","severity":"error","ruleIdentifier":"force_cast"}},{"text":" XCTAssertEqual(switchValue as! String, \"1\")","violation":{"location":{"line":15,"character":36,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/DisplaySettingsTests.swift"},"reason":"Force casts should be avoided","ruleIdentifier":"force_cast","ruleName":"Force Cast","ruleDescription":"Force casts should be avoided","severity":"error"}},{"text":" XCTAssertEqual(switchValue as! String, \"0\")","violation":{"ruleDescription":"Force casts should be avoided","ruleIdentifier":"force_cast","severity":"error","reason":"Force casts should be avoided","ruleName":"Force Cast","location":{"line":32,"character":36,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/DisplaySettingsTests.swift"}}},{"text":" XCTAssertEqual(switchValueAfter as! String, \"1\")","violation":{"ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/DisplaySettingsTests.swift","character":41,"line":51},"severity":"error","ruleIdentifier":"force_cast","reason":"Force casts should be avoided"}},{"text":" secondWebsite.url.contains(url.value! as! String), \"The tab has not been dropped correctly\"","violation":{"severity":"error","ruleDescription":"Force casts should be avoided","reason":"Force casts should be avoided","ruleIdentifier":"force_cast","ruleName":"Force Cast","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/DragAndDropTests.swift","line":112,"character":59}}},{"text":" secondWebsite.url.contains(url.value! as! String), \"The tab has not been dropped correctly\"","violation":{"ruleDescription":"Force casts should be avoided","severity":"error","ruleName":"Force Cast","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/DragAndDropTests.swift","character":59,"line":140},"reason":"Force casts should be avoided","ruleIdentifier":"force_cast"}},{"text":" secondWebsite.url.contains(app.textFields[AccessibilityIdentifiers.Browser.UrlBar.url].value! as! String),","violation":{"ruleName":"Force Cast","reason":"Force casts should be avoided","location":{"line":269,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/DragAndDropTests.swift","character":107},"ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided","severity":"error"}},{"text":" private func validateLayoutOnWalmartAndBestBuy(_ website: String, isWalmart: Bool, _ currentWebsite: String,","violation":{"severity":"warning","ruleName":"Multiline Parameters","ruleIdentifier":"multiline_parameters","location":{"line":263,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/FakespotTests.swift","character":18},"reason":"Functions and methods parameters should be either on the same line, or one per line","ruleDescription":"Functions and methods parameters should be either on the same line, or one per line"}},{"text":" if app.switches[\"SystemThemeSwitchValue\"].value! as! String == \"0\" {","violation":{"location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/FakespotTests.swift","character":58,"line":333},"ruleDescription":"Force casts should be avoided","reason":"Force casts should be avoided","ruleIdentifier":"force_cast","ruleName":"Force Cast","severity":"error"}},{"text":"func createScreenGraph(for test: XCTestCase, with app: XCUIApplication) -> MMScreenGraph<FxUserState> {","violation":{"ruleName":"Function Body Length","severity":"error","reason":"Function body should span 122 lines or less excluding comments and whitespace: currently spans 774 lines","location":{"line":263,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/FxScreenGraph.swift","character":1},"ruleIdentifier":"function_body_length","ruleDescription":"Function bodies should not span too many lines"}},{"text":" map.addScreenState(BrowserTab) { screenState in","violation":{"severity":"error","location":{"character":36,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/FxScreenGraph.swift","line":952},"reason":"Closure body should span 34 lines or less excluding comments and whitespace: currently spans 44 lines","ruleDescription":"Closure bodies should not span too many lines","ruleIdentifier":"closure_body_length","ruleName":"Closure Body Length"}},{"text":" map.addScreenState(BrowserTabMenu) { screenState in","violation":{"ruleName":"Closure Body Length","ruleDescription":"Closure bodies should not span too many lines","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/FxScreenGraph.swift","character":40,"line":1087},"ruleIdentifier":"closure_body_length","reason":"Closure body should span 34 lines or less excluding comments and whitespace: currently spans 91 lines","severity":"error"}},{"text":" app.cells.switches[\"Thought-Provoking Stories, Articles powered by Pocket\"].value as! String,","violation":{"severity":"error","reason":"Force casts should be avoided","ruleName":"Force Cast","ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/HomePageSettingsUITest.swift","line":392,"character":95}}},{"text":" app.switches[AccessibilityIdentifiers.Settings.Tabs.Customize.inactiveTabsSwitch].value as! String, \"1\")","violation":{"ruleIdentifier":"force_cast","ruleName":"Force Cast","severity":"error","location":{"character":101,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/InactiveTabsTest.swift","line":61},"reason":"Force casts should be avoided","ruleDescription":"Force casts should be avoided"}},{"text":" app.switches[AccessibilityIdentifiers.Settings.Tabs.Customize.inactiveTabsSwitch].value as! String, \"0\")","violation":{"location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/InactiveTabsTest.swift","line":64,"character":101},"ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","severity":"error","ruleIdentifier":"force_cast","reason":"Force casts should be avoided"}},{"text":" app.switches[AccessibilityIdentifiers.Settings.Tabs.Customize.inactiveTabsSwitch].value as! String, \"1\")","violation":{"severity":"error","ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","reason":"Force casts should be avoided","location":{"line":88,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/InactiveTabsTest.swift","character":101}}},{"text":" app.cells[\"DeviceNameSetting\"].textFields[\"DeviceNameSettingTextField\"].value! as! String,","violation":{"ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","location":{"character":92,"line":148,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/IntegrationTests.swift"},"ruleIdentifier":"force_cast","severity":"error","reason":"Force casts should be avoided"}},{"text":" XCTAssertEqual(app.switches[\"Jump Back In\"].value as! String, \"1\")","violation":{"reason":"Force casts should be avoided","ruleIdentifier":"force_cast","ruleName":"Force Cast","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/JumpBackInTests.swift","line":30,"character":59},"severity":"error","ruleDescription":"Force casts should be avoided"}},{"text":" XCTAssertEqual(tabButtonSecondWindow.value as! String, \"2\", \"Number of tabs opened should be equal to 2\")","violation":{"ruleIdentifier":"force_cast","severity":"error","location":{"line":54,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/MultiWindowTests.swift","character":52},"reason":"Force casts should be avoided","ruleDescription":"Force casts should be avoided","ruleName":"Force Cast"}},{"text":" XCTAssertEqual(tabButtonFirstWindow.value as! String, \"2\", \"Number of tabs opened should be equal to 2\")","violation":{"ruleIdentifier":"force_cast","severity":"error","ruleName":"Force Cast","reason":"Force casts should be avoided","ruleDescription":"Force casts should be avoided","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/MultiWindowTests.swift","line":62,"character":51}}},{"violation":{"ruleDescription":"Force casts should be avoided","severity":"error","location":{"character":77,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/NewTabSettings.swift","line":73},"reason":"Force casts should be avoided","ruleName":"Force Cast","ruleIdentifier":"force_cast"},"text":" let valueTyped = app.textFields[\"NewTabAsCustomURLTextField\"].value as! String"},{"violation":{"ruleDescription":"Force casts should be avoided","ruleIdentifier":"force_cast","reason":"Force casts should be avoided","location":{"character":52,"line":12,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/NoImageTests.swift"},"ruleName":"Force Cast","severity":"error"},"text":" XCTAssertEqual(noImageStatusMode.value as! String, \"0\")"},{"violation":{"reason":"Force casts should be avoided","ruleName":"Force Cast","location":{"character":52,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/NoImageTests.swift","line":14},"ruleIdentifier":"force_cast","severity":"error","ruleDescription":"Force casts should be avoided"},"text":" XCTAssertEqual(noImageStatusMode.value as! String, \"1\")"},{"violation":{"ruleDescription":"Force casts should be avoided","location":{"line":45,"character":37,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/PocketTests.swift"},"severity":"error","reason":"Force casts should be avoided","ruleIdentifier":"force_cast","ruleName":"Force Cast"},"text":" XCTAssertNotEqual(url.value as! String, \"\", \"The url textField is empty\")"},{"violation":{"ruleIdentifier":"force_cast","reason":"Force casts should be avoided","ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","severity":"error","location":{"character":52,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/SettingsTests.swift","line":12}},"text":" XCTAssertEqual(noImageStatusMode.value as! String, \"0\")"},{"violation":{"ruleDescription":"Force casts should be avoided","severity":"error","ruleName":"Force Cast","reason":"Force casts should be avoided","location":{"line":14,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/SettingsTests.swift","character":52},"ruleIdentifier":"force_cast"},"text":" XCTAssertEqual(noImageStatusMode.value as! String, \"1\")"},{"violation":{"ruleDescription":"Force casts should be avoided","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/ThirdPartySearchTest.swift","character":85,"line":30},"severity":"error","ruleIdentifier":"force_cast","ruleName":"Force Cast","reason":"Force casts should be avoided"},"text":" var url = app.textFields[AccessibilityIdentifiers.Browser.UrlBar.url].value as! String"},{"violation":{"severity":"error","ruleDescription":"Force casts should be avoided","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/ThirdPartySearchTest.swift","character":85,"line":53},"ruleName":"Force Cast","reason":"Force casts should be avoided","ruleIdentifier":"force_cast"},"text":" var url = app.textFields[AccessibilityIdentifiers.Browser.UrlBar.url].value as! String"},{"violation":{"location":{"character":94,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/ToolbarTest.swift","line":46},"ruleIdentifier":"force_cast","reason":"Force casts should be avoided","ruleName":"Force Cast","ruleDescription":"Force casts should be avoided","severity":"error"},"text":" let valueMozilla = app.textFields[AccessibilityIdentifiers.Browser.UrlBar.url].value as! String"},{"violation":{"ruleIdentifier":"force_cast","severity":"error","ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","location":{"character":94,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/ToolbarTest.swift","line":84},"reason":"Force casts should be avoided"},"text":" let valueMozilla = app.textFields[AccessibilityIdentifiers.Browser.UrlBar.url].value as! String"},{"violation":{"severity":"error","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/ToolbarTest.swift","line":167,"character":91},"ruleName":"Force Cast","reason":"Force casts should be avoided","ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided"},"text":" XCTAssertEqual(app.buttons[AccessibilityIdentifiers.Toolbar.tabsButton].value as! String, \"2\")"},{"violation":{"ruleName":"Force Cast","ruleDescription":"Force casts should be avoided","location":{"line":77,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/TopTabsTest.swift","character":94},"ruleIdentifier":"force_cast","reason":"Force casts should be avoided","severity":"error"},"text":" let valueMozilla = app.textFields[AccessibilityIdentifiers.Browser.UrlBar.url].value as! String"},{"violation":{"ruleName":"Force Cast","location":{"line":85,"character":87,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/TopTabsTest.swift"},"severity":"error","reason":"Force casts should be avoided","ruleIdentifier":"force_cast","ruleDescription":"Force casts should be avoided"},"text":" let value = app.textFields[AccessibilityIdentifiers.Browser.UrlBar.url].value as! String"},{"violation":{"reason":"Force casts should be avoided","ruleDescription":"Force casts should be avoided","ruleIdentifier":"force_cast","severity":"error","ruleName":"Force Cast","location":{"character":24,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/TrackingProtectionTests.swift","line":139}},"text":" if switchValue as! String == \"0\" {"},{"violation":{"location":{"character":36,"line":143,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/TrackingProtectionTests.swift"},"ruleIdentifier":"force_cast","ruleName":"Force Cast","severity":"error","ruleDescription":"Force casts should be avoided","reason":"Force casts should be avoided"},"text":" XCTAssertEqual(switchValue as! String, \"1\")"},{"violation":{"ruleDescription":"Force casts should be avoided","ruleName":"Force Cast","severity":"error","ruleIdentifier":"force_cast","location":{"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/TrackingProtectionTests.swift","line":147,"character":39},"reason":"Force casts should be avoided"},"text":" XCTAssertEqual(switchValueOFF as! String, \"0\")"},{"violation":{"ruleIdentifier":"force_cast","reason":"Force casts should be avoided","location":{"line":153,"character":44,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/TrackingProtectionTests.swift"},"ruleName":"Force Cast","severity":"error","ruleDescription":"Force casts should be avoided"},"text":" XCTAssertEqual(switchSettingsValue as! String, \"1\")"},{"violation":{"location":{"line":48,"file":"firefox-ios\/firefox-ios-tests\/Tests\/XCUITests\/UrlBarTests.swift","character":34},"ruleDescription":"Force casts should be avoided","reason":"Force casts should be avoided","ruleName":"Force Cast","severity":"error","ruleIdentifier":"force_cast"},"text":" XCTAssertEqual(url.value as! String, \"Search or enter address\")"}]