Un debut de test quand mm j'avais essayé...
git-svn-id: svn://scm.gforge.inria.fr/svnroot/paradiseo@1647 331e1502-861f-0410-8da2-ba01fb791d7f
This commit is contained in:
parent
a4f6668c81
commit
10835c3a36
2 changed files with 35 additions and 0 deletions
16
branches/newMo/test/moTestClass.h
Normal file
16
branches/newMo/test/moTestClass.h
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
#ifndef _moTestClass_h
|
||||
#define _moTestClass_h
|
||||
|
||||
#include <EO.h>
|
||||
#include <neighborhood/moNeighbor.h>
|
||||
|
||||
typedef EO<int> Solution;
|
||||
|
||||
class moDummyNeighbor : public moNeighbor<Solution,int>{
|
||||
|
||||
virtual void eval(Solution & solution){}
|
||||
|
||||
virtual void move(Solution & solution){}
|
||||
};
|
||||
|
||||
#endif
|
||||
19
branches/newMo/test/t-moNeighbor.cpp
Normal file
19
branches/newMo/test/t-moNeighbor.cpp
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
#include "moTestClass.h"
|
||||
|
||||
#include <cassert>
|
||||
|
||||
int main(){
|
||||
|
||||
moDummyNeighbor n1;
|
||||
|
||||
// n1.fitness(12);
|
||||
|
||||
// moDummyNeighbor n2(n1);
|
||||
|
||||
// assert(n1.fitness() == n2.fitness());
|
||||
|
||||
// n3=n1;
|
||||
// assert(n1.fitness() == n3.fitness());
|
||||
|
||||
return EXIT_SUCCESS;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue