diff --git a/.arduino-ci.yml b/.arduino-ci.yml index 8f3be50..c922cc1 100644 --- a/.arduino-ci.yml +++ b/.arduino-ci.yml @@ -5,15 +5,4 @@ unittest: platforms: - uno libraries: - - "OneWire" -aux_libraries_for_ci: - - OneWire -aux_libraries_for_unittest: - - OneWire -configuration: - architecture: "avr" - board: "uno" -directories: - lib_dir: "$GITHUB_WORKSPACE/libraries" - arduino_dir: "$GITHUB_WORKSPACE" - arduino_libraries_dir: "$GITHUB_WORKSPACE/libraries" \ No newline at end of file + - "OneWire" \ No newline at end of file diff --git a/.github/workflows/arduino_test_runner.yml b/.github/workflows/arduino_test_runner.yml index 2e2e2a2..8121279 100644 --- a/.github/workflows/arduino_test_runner.yml +++ b/.github/workflows/arduino_test_runner.yml @@ -9,61 +9,6 @@ jobs: steps: - uses: actions/checkout@v3 - - name: Create mock headers - run: | - # Create directory structure for mock headers - mkdir -p $GITHUB_WORKSPACE/mock/avr/util - - # Create mock crc16.h - cat > $GITHUB_WORKSPACE/mock/avr/util/crc16.h << 'EOF' - #ifndef _UTIL_CRC16_H_ - #define _UTIL_CRC16_H_ - - #include - - static inline uint16_t _crc16_update(uint16_t crc, uint8_t data) { - return (crc << 8) | data; - } - - #endif - EOF - - # Create mock pgmspace.h - cat > $GITHUB_WORKSPACE/mock/avr/pgmspace.h << 'EOF' - #ifndef __PGMSPACE_H_ - #define __PGMSPACE_H_ - - #include - - #define PROGMEM - #define PGM_P const char * - #define PSTR(str) (str) - - #define pgm_read_byte(addr) (*(const unsigned char *)(addr)) - #define pgm_read_word(addr) (*(const unsigned short *)(addr)) - #define pgm_read_dword(addr) (*(const unsigned long *)(addr)) - #define pgm_read_float(addr) (*(const float *)(addr)) - - #define strlen_P(s) strlen((const char *)(s)) - #define strcpy_P(dest, src) strcpy((char *)(dest), (const char *)(src)) - #define strncpy_P(dest, src, n) strncpy((char *)(dest), (const char *)(src), (n)) - - #endif - EOF - - # Create mock inttypes.h - cat > $GITHUB_WORKSPACE/mock/inttypes.h << 'EOF' - #ifndef _INTTYPES_H - #define _INTTYPES_H - - #include - - typedef int32_t int_farptr_t; - typedef uint32_t uint_farptr_t; - - #endif - EOF - - name: Create required directories run: | mkdir -p $GITHUB_WORKSPACE/bin @@ -74,19 +19,6 @@ jobs: - name: Setup Arduino CLI uses: arduino/setup-arduino-cli@v1 - - name: Configure Arduino CLI - run: | - cat > "$GITHUB_WORKSPACE/arduino-cli.yaml" << EOF - directories: - data: $GITHUB_WORKSPACE/.arduino15 - downloads: $GITHUB_WORKSPACE/.arduino15/staging - user: $GITHUB_WORKSPACE/libraries - board_manager: - additional_urls: [] - library: - enable_unsafe_install: true - EOF - - name: Install Arduino cores run: | arduino-cli core update-index @@ -103,10 +35,8 @@ jobs: - name: Install Arduino CI run: | - gem install arduino_ci -v 1.6.2 + gem install arduino_ci -v 1.5.0 - name: Run Arduino CI Tests - env: - CPLUS_INCLUDE_PATH: ${{ github.workspace }}/mock:$CPLUS_INCLUDE_PATH run: | arduino_ci.rb \ No newline at end of file diff --git a/arduino-cli.yaml b/arduino-cli.yaml index f7129d2..a3feda1 100644 --- a/arduino-cli.yaml +++ b/arduino-cli.yaml @@ -5,7 +5,7 @@ daemon: directories: data: $GITHUB_WORKSPACE/.arduino15 downloads: $GITHUB_WORKSPACE/.arduino15/staging - user: $GITHUB_WORKSPACE/Arduino + user: $GITHUB_WORKSPACE/libraries library: enable_unsafe_install: true logging: diff --git a/mock/avr/pgmspace.h b/mock/avr/pgmspace.h deleted file mode 100644 index 0b82adc..0000000 --- a/mock/avr/pgmspace.h +++ /dev/null @@ -1,19 +0,0 @@ -#ifndef __PGMSPACE_H_ -#define __PGMSPACE_H_ - -#include - -#define PROGMEM -#define PGM_P const char * -#define PSTR(str) (str) - -#define pgm_read_byte(addr) (*(const unsigned char *)(addr)) -#define pgm_read_word(addr) (*(const unsigned short *)(addr)) -#define pgm_read_dword(addr) (*(const unsigned long *)(addr)) -#define pgm_read_float(addr) (*(const float *)(addr)) - -#define strlen_P(s) strlen((const char *)(s)) -#define strcpy_P(dest, src) strcpy((char *)(dest), (const char *)(src)) -#define strncpy_P(dest, src, n) strncpy((char *)(dest), (const char *)(src), (n)) - -#endif diff --git a/mock/avr/util/crc16.h b/mock/avr/util/crc16.h deleted file mode 100644 index 74e8b2e..0000000 --- a/mock/avr/util/crc16.h +++ /dev/null @@ -1,10 +0,0 @@ -#ifndef _UTIL_CRC16_H_ -#define _UTIL_CRC16_H_ - -#include - -static inline uint16_t _crc16_update(uint16_t crc, uint8_t data) { - return (crc << 8) | data; -} - -#endif diff --git a/mock/inttypes.h b/mock/inttypes.h deleted file mode 100644 index 8dba81a..0000000 --- a/mock/inttypes.h +++ /dev/null @@ -1,16 +0,0 @@ -#ifndef _MOCK_INTTYPES_H -#define _MOCK_INTTYPES_H - -#include - -#ifndef _INT_FARPTR_T_DEFINED -#define _INT_FARPTR_T_DEFINED -typedef int32_t int_farptr_t; -#endif - -#ifndef _UINT_FARPTR_T_DEFINED -#define _UINT_FARPTR_T_DEFINED -typedef uint32_t uint_farptr_t; -#endif - -#endif