Fix unit tests
This commit is contained in:
		
							parent
							
								
									b662348236
								
							
						
					
					
						commit
						1079a725d9
					
				| @ -1,6 +1,6 @@ | |||||||
| #include "NetworkSync.h" | #include "NetworkSync.h" | ||||||
| 
 | 
 | ||||||
| #define RC_DEBUG 1 | // #define RC_DEBUG 1
 | ||||||
| 
 | 
 | ||||||
| #ifdef RC_DEBUG | #ifdef RC_DEBUG | ||||||
| #include <Arduino.h> | #include <Arduino.h> | ||||||
| @ -33,8 +33,6 @@ void NetworkSync::ReceiveMessage(Roboid* roboid, unsigned char bytecount) { | |||||||
|   } |   } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| #include <Arduino.h> |  | ||||||
| 
 |  | ||||||
| // Actually, this is a kind of investigate...
 | // Actually, this is a kind of investigate...
 | ||||||
| void NetworkSync::ReceiveNetworkId() { | void NetworkSync::ReceiveNetworkId() { | ||||||
|   this->networkId = buffer[1]; |   this->networkId = buffer[1]; | ||||||
|  | |||||||
| @ -411,7 +411,7 @@ TEST(BB2B, ObstacleBoth) { | |||||||
|   // Roboid velocity
 |   // Roboid velocity
 | ||||||
|   Polar velocity = diffDrive->GetVelocity(); |   Polar velocity = diffDrive->GetVelocity(); | ||||||
|   EXPECT_FLOAT_EQ(velocity.distance, 1.0F); |   EXPECT_FLOAT_EQ(velocity.distance, 1.0F); | ||||||
|   EXPECT_FLOAT_EQ(velocity.angle.InDegrees(), 180.0F); |   EXPECT_FLOAT_EQ(velocity.angle.InDegrees(), -180.0F); | ||||||
| 
 | 
 | ||||||
|   float angularVelocity = diffDrive->GetAngularVelocity(); |   float angularVelocity = diffDrive->GetAngularVelocity(); | ||||||
|   EXPECT_FLOAT_EQ(angularVelocity, 0.0F); |   EXPECT_FLOAT_EQ(angularVelocity, 0.0F); | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user