Skip to content

Commit

Permalink
[UPGRADE] build simple pipeline for testing automatically (#3)
Browse files Browse the repository at this point in the history
Description:
   This commit suggests an automatically way to build a pipeline for testing ibus-unikey's commits or PR requests. Here is what i have done:

- Create a lightweight pipeline inside file commit.yaml for testing with each commit, it uses another repository to support building a new generic pineline. Each commit must be proved to be passed with this pipeline. This pipeline is build within the github action to make a better maintaining and forking.
- Create a heavy pipeline with UI testing inside. Still now, it only support ubuntu for testing and it's defined inside regression.yaml and .travis.yml. I don't suggest using github action since it doesn't support kvm which make the pipeline takes more time for verification.

Signed-off-by: Hung Nguyen Xuan Pham <[email protected]>
  • Loading branch information
hung0913208 committed May 27, 2020
1 parent 31894a0 commit e5109ae
Show file tree
Hide file tree
Showing 11 changed files with 1,396 additions and 1 deletion.
15 changes: 15 additions & 0 deletions .cirrus.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
task:
name:
only_if: $CIRRUS_BRANCH == 'Test'
container:
image: ubuntu:latest
memory: 10G
cpu: 4
kvm: true
prepare_environment_script:
- apt update
- apt install -y qemu git curl
fetch_base_libraries_script:
- ./Tests/Pipeline/Prepare.sh --dry-run
build_and_test_script:
- ./Base/Tests/Pipeline/Create.sh
19 changes: 19 additions & 0 deletions .github/workflows/commit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Verify commit with the simple test suite

on: [push, pull_request]

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
cxx: [g++, clang++]

steps:
- uses: actions/checkout@v2
- name: prepare
run: ./tests/pipeline/prepare.sh
- name: build and test
env:
CXX: ${{ matrix.cxx }}
run: ./tests/pipeline/build.sh
27 changes: 27 additions & 0 deletions .github/workflows/regression.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Check if the new PR is working well

on:
pull_request:
branchs:
- master

jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
cxx: [g++]

steps:
- uses: actions/checkout@v2
- name: update
run: sudo apt update
- name: prepare
run: while ! sudo apt install qemu; do if ! which qemu-system-x86_64; then sleep 1; else break; fi; done
- name: fetch base libraries
run: ./tests/pipeline/prepare.sh --dry-run
- name: build and test
env:
CXX: ${{ matrix.cxx }}
MEGA: ${{ secrets.MEGA }}
run: ./Base/Tests/Pipeline/Create.sh
314 changes: 314 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,317 @@ po/insert-header.sin
po/quot.sed
po/remove-potcdate.sin
po/POTFILES

###Python###

# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so
###PyCharm###

# PyCharm
# http://www.jetbrains.com/pycharm/webhelp/project.html
.idea
.iml

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
.hypothesis/

# Translations
*.mo
*.pot

# Django stuff:
*.log
.static_storage/
.media/
local_settings.py

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
target/

# Jupyter Notebook
.ipynb_checkpoints

# pyenv
.python-version

# celery beat schedule file
celerybeat-schedule

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/


###Java###

# Compiled class file
*.class

# Log file
*.log

# BlueJ files
*.ctxt

# Mobile Tools for Java (J2ME)
.mtj.tmp/

# Package Files #
*.jar
*.war
*.ear
*.zip
*.tar.gz
*.rar

# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
hs_err_pid*


###C###
# Object files
*.o
*.ko
*.obj
*.elf

# Linker output
*.ilk
*.map
*.exp

# Precompiled Headers
*.gch
*.pch

# Libraries
*.lib
*.a
*.la
*.lo

# Shared objects (inc. Windows DLLs)
*.dll
*.so
*.so.*
*.dylib

# Executables
*.exe
*.out
*.app
*.i*86
*.x86_64
*.hex

# Debug files
*.dSYM/
*.su
*.idb
*.pdb

# Kernel Module Compile Results
*.mod*
*.cmd
.tmp_versions/
modules.order
Module.symvers
Mkfile.old
dkms.conf


###C++###

# Compiled Object files
*.slo
*.lo
*.o
*.obj

# Precompiled Headers
*.gch
*.pch

# Compiled Dynamic libraries
*.so
*.dylib
*.dll

# Fortran module files
*.mod
*.smod

# Compiled Static libraries
*.lai
*.la
*.a
*.lib

# Executables
*.exe
*.out
*.app


###vim###

[._]*.s[a-w][a-z]
[._]s[a-w][a-z]
*.un~
Session.vim
.netrwhist
*~


###gcov###

# gcc coverage testing tool files

*.gcno
*.gcda
*.gcov


###Gcov###

# gcc coverage testing tool files

*.gcno
*.gcda
*.gcov


###SublimeText###

# cache files for sublime text
*.tmlanguage.cache
*.tmPreferences.cache
*.stTheme.cache

# workspace files are user-specific
*.sublime-workspace

# project files should be checked into the repository, unless a significant
# proportion of contributors will probably not be using SublimeText
*.sublime-project

# sftp configuration file
sftp-config.json


###D###

# Compiled Object files
*.o
*.obj

# Compiled Dynamic libraries
*.so
*.dylib
*.dll

# Compiled Static libraries
*.a
*.lib

# Executables
*.exe

# DUB
.dub
docs.json
__dummy.html
docs/

# Code coverage
*.lst

# Tools/Builder
output/.vscode/
Eevee.xcodeproj/
.tags_sorted_by_file
.tags
.DS_Store
tags

# vim
*.config
*.vim
.lvimrc

# Xcode
*.xcworkspace
16 changes: 16 additions & 0 deletions .requirement.d/debian
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
gdb
lcov
make
pxelinux
syslinux-common
cmake
atftpd
sshpass
megatools
libx11-dev
libibus-1.0-dev
libgtk-3-dev
genisoimage
squashfs-tools
nfs-ganesha
nfs-kernel-server
Loading

0 comments on commit e5109ae

Please sign in to comment.