Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Znak created an issue. See original summary.

Znak’s picture

Issue summary: View changes
Znak’s picture

Assigned: Znak » Unassigned
Status: Needs work » Needs review
FileSize
12.63 KB

Patch for fix this. Please, check up.

elachlan’s picture

Version: 8.x-1.0-alpha0 » 8.x-1.x-dev

Can you please link the change notices for each of the issues in the description?

Also all changes are to dev.

Status: Needs review » Needs work

The last submitted patch, 3: deprecated_methods_and_function-2855165-3.patch, failed testing.

alunyov’s picture

Status: Needs work » Needs review

Hello Guys,
I have updated patch, because there were two critical issues were causing failing tests:
1st is about loading entity form display
2nd is about the way how drupal_render_children() was replaced
Additionally I have replaced \Drupal::database()->query() (where SELECT is called) with \Drupal::database()->select(), since that is more Drupal way.
Please review the patch,

alunyov’s picture

gg24’s picture

Status: Needs review » Reviewed & tested by the community
FileSize
77.28 KB

Testing steps are as follows:-

  1. Enabled Captcha Module.
  2. Enabled node_edit_form captcha point.
  3. Changed captcha settings accordingly.
  4. Created a new anonymous user.
  5. Added edit and add node permission to it.
  6. Tried creating a new node and tried editing the node from this particular user.
  7. If i put wrong captcha, it gives error to me.
  8. Everything works as expected.

Attaching screenshot for the captcha here too. #7 Patch works as expected. Issuing RTBC to this.

Thanks!

bapi_22’s picture

Status: Reviewed & tested by the community » Needs review

Avoid static method call inside Class method, use dependency injection instead.

alunyov’s picture

I have updated patch. Added dependency injections to Captcha, CaptchaCachedSettingsSubscriber, CaptchaExamplesForm, CaptchaPointForm and CaptchaSettingsForm classes even that was not requested initially.
@gg24, @bapi_22 feel free to check it now.
P.S. locally tests are run without issues.

  • elachlan committed bdd0e74 on 8.x-1.x authored by alunyov
    Issue #2855165 by alunyov, Znak, gg24, bapi_22: Deprecated methods and...
elachlan’s picture

I've committed the changes so the patches aren't so massive. So it should be easier to tweak if necessary.

bapi_22’s picture

Status: Needs review » Needs work

Hi alunyov,

Looks good Now.
As REQUEST_TIME is deprecated, so try to use \Drupal::time()->getRequestTime() instead.

Thanks

alunyov’s picture

Hey bapi_22,
Here is new patch to replace deprecated REQUEST_TIME. Tests run locally fine.

alunyov’s picture

Status: Needs work » Needs review

Marking the issue as 'Needs review'

bapi_22’s picture

Status: Needs review » Reviewed & tested by the community

#14 Looks good
+1 to RTBC

  • elachlan committed f3201a7 on 8.x-1.x authored by alunyov
    Issue #2855165 by alunyov, Znak, gg24, elachlan: Deprecated methods and...
elachlan’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

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