Sha256: c29fa69264fd62d7a466a95de9c927e94119b366ecb1d333be47c60de6183fa1

Contents?: true

Size: 775 Bytes

Versions: 14

Compression:

Stored size: 775 Bytes

Contents

#include "unity.h"
#include "Types.h"
#include "UsartHardware.h"
#include "AT91SAM7X256.h"
#include "MockUsartConfigurator.h"
#include "MockUsartPutChar.h"

void setUp(void)
{
}

void tearDown(void)
{
}

void testInitShouldConfigureUsartPeripheralByCallingConfiguratorAppropriately(void)
{
  Usart_ConfigureUsartIO_Expect();
  Usart_EnablePeripheralClock_Expect();
  Usart_Reset_Expect();
  Usart_ConfigureMode_Expect();
  Usart_SetBaudRateRegister_Expect(73);
  Usart_Enable_Expect();

  UsartHardware_Init(73);
}

void testTransmitStringShouldSendDesiredStringOutUsingUsart(void)
{
  Usart_PutChar_Expect('h');
  Usart_PutChar_Expect('e');
  Usart_PutChar_Expect('l');
  Usart_PutChar_Expect('l');
  Usart_PutChar_Expect('o');
  
  UsartHardware_TransmitString("hello");
}

Version data entries

14 entries across 14 versions & 1 rubygems

Version Path
ceedling-0.31.1 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.31.0 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.30.0 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.28.3 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.28.2 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.28.1 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.27.0 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.25.0 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.24.0 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.22.0 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.21.0 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.20.3 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.20.2 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c
ceedling-0.19.0 vendor/cmock/examples/temp_sensor/test/TestUsartHardware.c