1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-06-12 01:53:07 +03:00

Initial batch of mocks for host side testing

This commit is contained in:
Ivan Grokhotkov
2016-03-03 09:37:35 +03:00
parent 1c9f9c3a6d
commit 5724f38542
8 changed files with 10033 additions and 0 deletions

View File

@ -0,0 +1,29 @@
//
// Arduino.cpp
// esp8266-host-tests
//
// Created by Ivan Grokhotkov on 02/03/16.
// Copyright © 2016 esp8266.com. All rights reserved.
//
#define CATCH_CONFIG_MAIN
#include <catch.hpp>
#include <sys/time.h>
#include "Arduino.h"
extern "C" unsigned long millis()
{
timeval time;
gettimeofday(&time, NULL);
return (time.tv_sec * 1000) + (time.tv_usec / 1000);
}
extern "C" void yield()
{
}
extern "C" void __panic_func(const char* file, int line, const char* func) {
abort();
}