Skip to content
Snippets Groups Projects
Commit 6785e543 authored by Le-Bao-Tin.Ha's avatar Le-Bao-Tin.Ha
Browse files

add test DS and test Prof

parent bc8cf842
No related branches found
No related tags found
4 merge requests!8Modele,!7Modele,!6Modele,!5Modele Version 1
googletest @ e8512bc3
Subproject commit e8512bc38c4c0060858c3306b0660a3f126aee30
/*
// Created by Tiny on 3/18/2021.
*/
#ifndef MAIN_C_TEST_DS_H
#define MAIN_C_TEST_DS_H
#include <gtest/gtest.h>
extern "C"{
#include "DS.h"
}
TEST(test_init_DS,Door_3){
DS exam;
init_DS(&exam,3,"testimage");
EXPECT_STREQ("testimage",exam.image_DS);
EXPECT_EQ(369,exam.x_DS);
EXPECT_EQ(41,exam.y_DS);
EXPECT_EQ(21,exam.larg_DS);
EXPECT_EQ(10,exam.long_DS);
}
#endif /*MAIN_C_TEST_DS_H*/
......@@ -29,6 +29,6 @@ TEST(test_calcul_point,values_3_3){
EXPECT_EQ(6,person.y_ll);
EXPECT_EQ(6,person.x_lr);
EXPECT_EQ(6,person.y_lr);
}
#endif /*INSAGAME_TEST_PERSONNAGE_H*/
/*
// Created by Tiny on 3/18/2021.
*/
#ifndef MAIN_C_TEST_PROF_H
#define MAIN_C_TEST_PROF_H
#include <gtest/gtest.h>
extern "C"{
#include "prof.h"
}
TEST(test_init_prof,values_3_3_3_3_3_testimage){
Prof prof;
init_prof(&prof,3,3,3,3,3,"testimage");
EXPECT_EQ(3,prof.x_prof);
EXPECT_EQ(3,prof.y_prof);
EXPECT_EQ(3,prof.long_prof);
EXPECT_EQ(3,prof.larg_prof);
EXPECT_STREQ("testimage",prof.image_prof);
}
#endif /*MAIN_C_TEST_PROF_H*/
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment