# Thread: Testing Dynamic Loop

1. ## Testing Dynamic Loop

Hello All,

How to test a functionality which assigns the values of two sets of data?

Let's call the first set Assignment and the second set Assignee.

Assignment is a list of tasks which are automatically generated and will never be empty. Assignee is a list of people whom the tasks will be assigned to. This list of people will be dynamic because of sickness, holiday, etc.

A task will be allocated to a free Assignee. When the first assignee is occupied, the system will move the task to the second assignee. This goes on until a free Assignee is found.

How to test this functionality?

Many thanks for reading this.

S

2. ## Re: Testing Dynamic Loop

Is this a manual test or automated test? If automated, i'd probably use a Semaphore to handle tracking the pool of Assignees. I'm assuming you don't have control over the order which the asignees finish their task, other wise a simple sequence will suffice.

http://en.wikipedia.org/wiki/Semaphore_(programming)

I've used this programming pattern in programming for tracking parallel threads and dispatching tasks to them.

3. ## Re: Testing Dynamic Loop

Manual testing first. But, I would like to be able to do this automatically. No, I don't have control to the finish time.

4. ## Re: Testing Dynamic Loop

To the OP, please try to formulate the problem in a discrete mathematical problem.
This particular problem is well known and is called :-
[http://en.wikipedia.org/wiki/Assignment_problem]

5. ## Re: Testing Dynamic Loop

nmondal, I appreciate that you might be a mathematical genius (and certainly a fan of mathematical analysis.) But your posts tend to be WAY too academic for the average member here.

6. ## Re: Testing Dynamic Loop

The problem in current form is vague, and as usual almost can never be tested, forget perfection. Peter Ruscoe, thanks for the kind words, but the people I learned from were not mathematical genius, they taught me to see through the problem.
And me no genius either, however I have seen some for the course of my life.
In this particular case, unless one does not understand the right algorithm, one can not test it.
For example one paper is right here:-

[http://www.jstor.org/pss/170800]

Can the OP -- elaborate on what is the exact algorithm used?

7. ## Re: Testing Dynamic Loop

Actually, I think the original post described the algorithm quite well. But not in mathematical terms. And that is probably what bothers you.

[ QUOTE ]
unless one does not understand the right algorithm, one can not test it.

[/ QUOTE ]
Ignoring the grammatical problem (which, I believe, negates what you are actually trying to say,) are you SERIOUSLY suggesting that one must ALWAYS understand the underlying logic of a system in order to test it? That is not only unrealistic, it only represents a tiny number of real-life cases. Do you, nmondal, work as a tester in the "real world?"

8. ## Re: Testing Dynamic Loop

I am sorry that I make lots of grammatical mistakes, truly I am.
English is not my first language, but that is not an excuse.
Problem remains however:-
=====================================
Let's call the first set Assignment and the second set Assignee.

Assignment is a list of tasks which are **automatically generated** and will never be empty. Assignee is a list of people whom the tasks will be assigned to. This list of people will be **[dynamic because of sickness, holiday, etc]**.

A task will be allocated to a free Assignee. When the first assignee is occupied, the system will move the task to the **second assignee**. This goes on until a **free Assignee** is found.
=================================

This qualifies as *obviously quite well depicted algorithm*.
Sedgewick or Knuth or Beizier probably wont agree.

As it is established (w/o seeing my resume) that I don't do *real world testing* I am sorry to post an answer.

9. ## Re: Testing Dynamic Loop

Oh, come ON! You are a mathematician. Nothing in the OP said that the assignee was a real, living, breathing human being. It is an ABSTRACT concept. Surely you can recognize that?

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts
•

vBulletin Optimisation provided by vB Optimise v2.6.0 Beta 4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.0.9 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Questions / Answers Form provided by vBAnswers (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominatevBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 08:55 AM.