* Set up comments without a subject. Check that the subject field is not there.
* Set up comments to have a subject. Preview, submit, reply, edit, delete a comment. Check the reply is gone too.
* Set Preview comment to required. check that it is indeed required.
* Check both locations of the comment submission form work: the form and submissions works.
* Check all three options of anonymous commenting: leave comments with or without contact information as appropriate
* Check admin/content/comment and admin/content/comment/approval for correctness: publish / unpublish / delete a comment. Post a comment with a user that has no "post comments without approval" only "post comments" and check the comment is not visible for other users. Approve it and see it is.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

boombatower’s picture

Status: Active » Needs review
FileSize
11.86 KB

I believe this beast is working.

kourge’s picture

Title: GHOP #164 Create tests for comemnt module » GHOP #164 Create tests for comment module
webchick’s picture

Status: Needs review » Needs work

- // $Id: should be // $Id$
- Your test needs a description more descriptive than "..." :)
- No need to override tearDown if you're not actually performing tearDown tasks.
- Instead of set_comment_settings business, I'd just do a plain $this->variableSet(); for those form values. This has the advantage of cleaning up after your test so you don't permanently alter the state of the database.
- Let's get some Doxygen comments on those functions, hmm? ;)
- I wonder if these should be broken up a little into different test* functions, rather than all chunked under testComment. That's a /long/ function. Is there a nice place to split up the functionality? (ex: testEdit, testAnonymous, testDelete, test...)

Sorry, I'm too tired to do a more thorough functionality review, atm. Will leave to chx/Zlender.

boombatower’s picture

FileSize
13.46 KB

Summary:

  • Fixed $Id.
  • Forgot about that. I usually leave that till last so I can make it most accurate. Fixed.
  • Was told that I needed that regardless by cwgordon7. Removed.
  • Changed.
  • Yea the Doxygen was intended to be filled out just figured that some other changes would be found so I would give you guys the most time to see it. Sorry, fixed.
  • Possible later is what chx said.

Thanks for reviewing it.

webchick’s picture

Status: Needs work » Needs review

Marking back for review.

boombatower’s picture

FileSize
14.04 KB

I believe I successfully split up tasks.

Rok Žlender’s picture

Status: Needs review » Reviewed & tested by the community

Tests looks great. I went over the code and couldn't find any problems. Tomorrow I'll try running the test and will commit afterwards. This is amazing test thanks boombatower.

Rok Žlender’s picture

Committed to D6 branch now testing for head.

Rok Žlender’s picture

Status: Reviewed & tested by the community » Fixed

Committed to HEAD.

Anonymous’s picture

Status: Fixed » Closed (fixed)

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