Skip to content

Commit

Permalink
Remove unused variables or constants
Browse files Browse the repository at this point in the history
  • Loading branch information
bozidarsevo committed Dec 24, 2024
1 parent fa42469 commit 13aa13a
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1140,8 +1140,6 @@ extension ProductsViewController: UITableViewDelegate {
}

func tableView(_ tableView: UITableView, willDisplay cell: UITableViewCell, forRowAt indexPath: IndexPath) {
let productIndex = resultsController.objectIndex(from: indexPath)

// Preserve the Cell Height
// Why: Because Autosizing Cells, upon reload, will need to be laid yout yet again. This might cause
// UI glitches / unwanted animations. By preserving it, *then* the estimated will be extremely close to
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ final class OrderNotificationViewModelTests: XCTestCase {

extension OrderNotificationViewModelTests {
func sampleNote() -> Note {
let storeTitle = "My Test Store"
let range = NoteRange.fake().copy(range: .init(location: 23, length: 13))
let block = NoteBlock.fake().copy(ranges: [range], text: "You have a new Order - My Test Store")
return Note.fake().copy(subject: [block])
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,6 @@ final class ProductStockDashboardCardViewModelTests: XCTestCase {

let variation = ProductStock.fake().copy(siteID: siteID, productID: 44, parentID: 40)

let thumbnailURL = "https://example.com/image.jpg"
let variationReport = ProductReport.fake().copy(productID: 0, // missing product ID happens to some stores
variationID: variation.productID,
name: "Pizza - Large, Seafood, Spicy",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,6 @@ final class WooPaymentsPayoutsCurrencyOverviewViewModelTests: XCTestCase {

func test_when_currency_matches_site_settings_amounts_formatted_using_woo_currency_formatter() {
// Given
let currencySettings = CurrencySettings(currencyCode: .USD,
currencyPosition: .left,
thousandSeparator: ",",
decimalSeparator: ".",
numberOfDecimals: 2)
let overview = WooPaymentsPayoutsOverviewByCurrency.fake().copy(currency: .USD, availableBalance: .init(string: "12.35"))

// When
Expand All @@ -74,11 +69,6 @@ final class WooPaymentsPayoutsCurrencyOverviewViewModelTests: XCTestCase {

func test_when_currency_doesnt_match_site_settings_amounts_formatted_using_system_locale_currency_formatter() {
// Given
let currencySettings = CurrencySettings(currencyCode: .USD,
currencyPosition: .left,
thousandSeparator: ",",
decimalSeparator: ".",
numberOfDecimals: 2)
let overview = WooPaymentsPayoutsOverviewByCurrency.fake().copy(currency: .CAD, availableBalance: .init(string: "12.35"))

// When
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,6 @@ final class InAppFeedbackCardVisibilityUseCaseTests: XCTestCase {

func test_orderFormShippingLines_shouldBeVisible_is_true_if_feedback_status_is_pending() throws {
// Given
let lastFeedbackDate = try date(from: "2020-11-06T00:00:00Z")
let currentDate = try date(from: "2020-11-12T23:59:59Z")

fileManager.whenRetrievingAttributesOfItem(atPath: try documentDirectoryURL().path, thenReturn: [:])
Expand All @@ -174,7 +173,6 @@ final class InAppFeedbackCardVisibilityUseCaseTests: XCTestCase {

func test_orderFormShippingLines_shouldBeVisible_is_false_if_feedback_status_is_dismissed() throws {
// Given
let lastFeedbackDate = try date(from: "2020-11-06T00:00:00Z")
let currentDate = try date(from: "2020-11-12T23:59:59Z")

fileManager.whenRetrievingAttributesOfItem(atPath: try documentDirectoryURL().path, thenReturn: [:])
Expand Down

0 comments on commit 13aa13a

Please sign in to comment.