robogals / myrobogals

myRobogals is the global intranet and record-keeping tool for Robogals. It has been built to simplify many of our day-to-day tasks including organising school visits, maintaining a member database, communicating with members, storing records reliably for future generations and easily collecting statistics on a global scale.
https://my.robogals.org
10 stars 21 forks source link

Import CSV Issue #23

Closed juneesingh17 closed 11 years ago

U-238 commented 11 years ago

Hi Junee,

Thanks for submitting this. As someone who is new to Django programming and myRobogals, you have done a good job!

There were however several areas for improvement:

To help guide you, I have put here some test cases for you to check your code with:

Test case: importing duplicate usernames in the same chapter, with the update option selected Expected outcome: the existing users are updated

Test case: importing duplicate usernames in the same chapter, with the update option not selected Expected outcome: the duplicate usernames are ignored, and the user is shown a message that there was a duplicate username

Test case: importing duplicate usernames in another chapter, with the update option selected Expected outcome: the duplicate usernames are ignored, and the user is shown a message that there was a duplicate username in another chapter

Test case: import duplicate emails, with the ignore email option selected Expected outcome: the duplicate emails are ignored, and the user is shown a message

Test case: import duplicate emails, with the ignore email option not selected Expected outcome: the new user accounts are created anyway, despite the duplicate emails

Test case: import a CSV file without a username column Expected outcome: the users are imported with an automatically-generated username

Here's the CSV file I was using to test without a username column:

first_name,last_name,email
Mark,Parncutt,mark@test3.com
Junee,Singh,junee@test3.com

That's all I could think of, if you can get it to pass all of those then please resubmit your pull request :)

Post questions here on Github if you need to.

I probably won't be able to look at further code until after I return from Brisbane, so please accept my apologies if I can't reply for the next week or so.

Good luck!

Cheers,

Mark