Comments

Sergiu Stici created an issue. See original summary.

sergiu stici’s picture

Status: Active » Needs review
StatusFileSize
new375 bytes

Here's the patch, please review.

elgandoz’s picture

StatusFileSize
new997 bytes
new855 bytes
elgandoz’s picture

Issue tags: +D9 readiness
elgandoz’s picture

Title: Deprecated Code Report » Drupal 9 Deprecated Code Report
kristen pol’s picture

Issue tags: -D9 readiness +Drupal 9 compatibility

Remove outdated tag.

ziomizar’s picture

StatusFileSize
new809 bytes
new1.24 KB

Added default theme in ContactAjaxTest and support drupal from 8.8

ziomizar’s picture

Status: Needs review » Needs work
ziomizar’s picture

Status: Needs work » Needs review
ziomizar’s picture

StatusFileSize
new378 bytes
new1.24 KB

Removing `core:` attribute from info file

kristen pol’s picture

Status: Needs review » Needs work

The line needs to stay there when changing back to ^8 from ^8.8. Please see https://twitter.com/kristen_pol/status/1263651488678572034?s=20.

mrinalini9’s picture

Assigned: Unassigned » mrinalini9
mrinalini9’s picture

Assigned: mrinalini9 » Unassigned
Status: Needs work » Needs review
StatusFileSize
new1.2 KB
new329 bytes

Updated patch as suggested in #11, please review.

kristen pol’s picture

Status: Needs review » Needs work

Thanks for the update. Nitpick:

+++ b/contact_ajax.info.yml
@@ -1,7 +1,8 @@
+name: Contact Ajax ¶

Extra space after name.

mrinalini9’s picture

Status: Needs work » Needs review
StatusFileSize
new1.24 KB
new247 bytes

Thanks for the review. I have updated the patch and fixed the extra spacing issue as mentioned in #14, please review.

ziomizar’s picture

StatusFileSize
new378 bytes
new1.24 KB

Ops was not intentional removing 8.8.
Thanks Kristen reverted to 8.8 and removed `core`

ziomizar’s picture

Status: Needs review » Needs work

Uh ok we need to convert also `drupalPostAjaxForm`

elgandoz’s picture

Status: Needs work » Needs review

To be fair Drupal\Tests\field_ui\Traits\FieldUiTestTrait has been introduced since 8.6.x. Also these classes concerns tests only and the module would still work on any 8.x version. Patch #15 should be used IMHO.

ziomizar’s picture

StatusFileSize
new7.96 KB
new8.11 KB

@elgandoz i still in doubt about the compatibility in the core version, i moved back to ^8 by the way.

The patch contain an idea of how the testes should look like without the submitAjaxForm method.
I haven't run yet this tests but it should be very close

ziomizar’s picture

StatusFileSize
new8.55 KB
new1.04 KB

Status: Needs review » Needs work

The last submitted patch, 20: deprecated-3094339-20.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

mukeshkanzariya’s picture

Issue summary: View changes
StatusFileSize
new1.38 KB

Make changes to make this module compatible with drupal9 as well.

mukeshkanzariya’s picture

Status: Needs work » Needs review

Status: Needs review » Needs work

The last submitted patch, 22: d9compatible-3094339-21.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

mukeshkanzariya’s picture

StatusFileSize
new1.6 KB
mukeshkanzariya’s picture

StatusFileSize
new1.97 KB
ziomizar’s picture

Hi mukeshkanzariya,

Please provide an interdiff when you work on an existing patch, will be easier follow the changes you did.
Also consider that the changes you did are not enough to use FunctionalJavascript, please see the patch in #20.
Can you argument your idea?

dom.’s picture

Patch #20 seems good and works.
Watch is missing for this module to have a D9 compatibility ? I'm ok to help if needed.

ziomizar’s picture

Issue summary: View changes
ziomizar’s picture

Issue summary: View changes

Hi Dom,

Tests are failing, is the only thing missing. But i guess is better split the task in 2 steps, so release a version compatible with D9 without tests and work on separate issue to fix them.

dom.’s picture

That would at least allow to a clean install of the module via composer (thus in CLI pipelines) on D9 projects.

neslee canil pinto’s picture

StatusFileSize
new1.44 KB
neslee canil pinto’s picture

StatusFileSize
new2.1 KB
dom.’s picture

Status: Needs work » Needs review
StatusFileSize
new17.58 KB
new9.35 KB

----------------------

/src/Tests/ContactAjaxTest.php

 namespace Drupal\contact_ajax\Tests;

tests should now be extracted from src and moved to a "tests" folder aside.

/src/Tests/ContactAjaxTest.php

/**
 * Tests storing contact messages and viewing them through UI.
 *
 * @group contact_storage
 */

Some copy-paste left-over.

/src/Tests/ContactAjaxTest.php

use FieldUiTestTrait;

This fills useless here

/src/Tests/ContactAjaxTest.php

$this->assertText()

Those are deprecated. I guess this is why they are not compatible with the JS tests here with the response header checks.

/src/Tests/ContactAjaxTest.php

$this->drupalPostAjaxForm()

This method maps to nothing
----------------------

I really would like to see this module happen for Drupal9 since it is somewhat difficult to not being able to use it via composer.

I have done somes changes in the test file (appart from moving it), mainly because of the 'javascript' process that runs on WebDriverTestBase. Contrarily to BrowserTestBase, JS is enabled and drupalPostForm where there is ajax involved is a bit more complicated to use.

Patch is attached and should (finger cross) pass test checks (as it does locally).

  • Dom. authored 1c25335 on 8.x-1.x
    Issue #3094339 by ziomizar, mukeshkanzariya, mrinalini9, Neslee Canil...

  • Neslee Canil Pinto authored 0c39d10 on 8.x-1.x
    Issue #3094339 by ziomizar, mukeshkanzariya, mrinalini9, Neslee Canil...
  • mukeshkanzariya authored 15dfd3f on 8.x-1.x
    Issue #3094339 by ziomizar, mukeshkanzariya, mrinalini9, Neslee Canil...
  • mrinalini9 authored 5f253dc on 8.x-1.x
    Issue #3094339 by ziomizar, mukeshkanzariya, mrinalini9, Neslee Canil...
  • Sergiu Stici authored 950d8b6 on 8.x-1.x
    Issue #3094339 by ziomizar, mukeshkanzariya, mrinalini9, Neslee Canil...
  • Kristen Pol authored 9f6be17 on 8.x-1.x
    Issue #3094339 by ziomizar, mukeshkanzariya, mrinalini9, Neslee Canil...
ziomizar’s picture

Status: Needs review » Fixed

Committed to dev.

Commit credit to all people involved,

Thank you.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.