expect(record.errors[:saledate]).toinclude("Enter a date within the 23/24 or 24/25 collection years, which is between 1st April 2023 and 31st March 2025")
expect(record.errors[:saledate]).toinclude("Enter a date within the 23/24 or 24/25 collection years, which is between 1st April 2023 and 31st March 2025.")
end
end
@ -105,7 +105,7 @@ RSpec.describe Validations::Sales::SetupValidations do
expect(record.errors[:saledate]).toinclude("Enter a date within the 23/24 or 24/25 collection years, which is between 1st April 2023 and 31st March 2025")
expect(record.errors[:saledate]).toinclude("Enter a date within the 23/24 or 24/25 collection years, which is between 1st April 2023 and 31st March 2025.")
end
end
@ -119,7 +119,7 @@ RSpec.describe Validations::Sales::SetupValidations do
it"cannot create new logs for the archived collection year"do
expect(record.errors["saledate"]).toinclude(match"Enter a date within the 23/24 or 24/25 collection years, which is between 1st April 2023 and 31st March 2025")
expect(record.errors["saledate"]).toinclude(match"Enter a date within the 23/24 or 24/25 collection years, which is between 1st April 2023 and 31st March 2025.")
end
it"can edit already created logs for the previous collection year"do
@ -127,7 +127,7 @@ RSpec.describe Validations::Sales::SetupValidations do
expect(record.errors["saledate"]).not_toinclude(match"Enter a date within the 24/25 collection year, which is between 1st April 2024 and 31st March 2025")
expect(record.errors["saledate"]).not_toinclude(match"Enter a date within the 24/25 collection year, which is between 1st April 2024 and 31st March 2025.")
end
end
@ -142,7 +142,7 @@ RSpec.describe Validations::Sales::SetupValidations do
expect(record.errors["saledate"]).toinclude(match"Enter a date within the 23/24 or 24/25 collection years, which is between 1st April 2023 and 31st March 2025")
expect(record.errors["saledate"]).toinclude(match"Enter a date within the 23/24 or 24/25 collection years, which is between 1st April 2023 and 31st March 2025.")
end
it"cannot edit already created logs for the archived collection year"do
@ -150,7 +150,7 @@ RSpec.describe Validations::Sales::SetupValidations do
expect(record.errors["saledate"]).toinclude(match"Enter a date within the 23/24 or 24/25 collection years, which is between 1st April 2023 and 31st March 2025")
expect(record.errors["saledate"]).toinclude(match"Enter a date within the 23/24 or 24/25 collection years, which is between 1st April 2023 and 31st March 2025.")