Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Contact admin page is not working! (admin/build/contact)
We collect the data in the $row array but we give the temlplate the name: $rows.
Here is a patch, please apply.
Sorry, I don't know what shall I do. I create a new issue and modify existing #302219: DBTNG: contact
Comment | File | Size | Author |
---|---|---|---|
#9 | 413060-2.patch | 1.08 KB | pp |
#6 | 413060.patch | 1.01 KB | pp |
302219-4.patch | 665 bytes | pp | |
Comments
Comment #1
mr.baileysYou are correct, looks like the 's' was accidentally dropped in #302219: DBTNG: contact.
Reviewed the patch and it looks good, applied the patch and it works as advertised.
Comment #2
webchickOops. :) Committed, thanks.
I thought about modifying the contact tests to catch this, but I'm not exactly sure how to do that given that the name shows up as part of the drupal_set_message().
Comment #3
mr.baileys@webchick: probably wise to add/change a test for this. The issue isn't the "category added message", which is taken care of already:
The problem is the categories table in the body of admin/build/contact. Tests should probably be changed to include assertions that the new category is appearing in the table. I think it's just a matter of adding one extra assertion to the existing tests.
Should this issue be re-opened for the test or should a new issue be created?
Comment #4
webchickWe can re-open this. I thought of changing that to just $this->assertText($category, t('Found the category')); but I'm not sure that would have failed, since it also appears in the drupal_set_message(). If we had to break into doing $this->assertXPath() or similar to make sure it was enclosed in table tags, that seems like it'd be pretty crazy and inconsistent with what we do elsewhere.
Comment #5
mr.baileysWell, we could either:
Both would be simpler than the XPath route.
@pp: since you wrote the initial patch, would you be willing to submit a new patch containing changes to the tests for this scenario?
Comment #6
pp CreditAttribution: pp commentedHere it is. (my english is not to good, please correct it.)
Test it. It catch this bug.
Comment #7
JamesAn CreditAttribution: JamesAn commentedJust moving the status to review for the patch submitted by pp.
Comment #8
mr.baileysHi pp, thanks for rolling this patch!
Some comments after reviewing the added test:
I also think it should be a bit more verbose (something like "Make sure the newly created category is included in the list of categories."?)
I haven't applied the patch yet, but other than the comments above it looks good. Can you re-roll this patch with these changes?
Comment #9
pp CreditAttribution: pp commentedThanks, mr.baileys!
I modified the patch.
But I think it isn't good. We inspect $category string presents twice(or more). The bug is "The table don't contains the $category name".
I probe following:
It isn't work(Don't assert when table isn't presented), but when I probe following:
it's work. (assert when table is presented)
I don't understand. (I'm studying the Drupal functional testing yet)
pp
Comment #11
JamesAn CreditAttribution: JamesAn commentedHmm.. this passed before. Wonder why it failed this time. =\
Comment #12
Dave Reid@JamesAn: Testing bot weirdness. :)
Looks good and I approve.
Comment #13
Dries CreditAttribution: Dries commentedCommitted to CVS HEAD. Thanks!