Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
ashwani-rathee committed Sep 30, 2023
1 parent 9cb8c82 commit 95ab54e
Show file tree
Hide file tree
Showing 13 changed files with 188 additions and 2 deletions.
16 changes: 16 additions & 0 deletions .github/workflows/CompatHelper.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: CompatHelper
on:
schedule:
- cron: 0 0 * * *
workflow_dispatch:
jobs:
CompatHelper:
runs-on: ubuntu-latest
steps:
- name: Pkg.add("CompatHelper")
run: julia -e 'using Pkg; Pkg.add("CompatHelper")'
- name: CompatHelper.main()
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COMPATHELPER_PRIV: ${{ secrets.DOCUMENTER_KEY }}
run: julia -e 'using CompatHelper; CompatHelper.main()'
15 changes: 15 additions & 0 deletions .github/workflows/TagBot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
name: TagBot
on:
issue_comment:
types:
- created
workflow_dispatch:
jobs:
TagBot:
if: github.event_name == 'workflow_dispatch' || github.actor == 'JuliaTagBot'
runs-on: ubuntu-latest
steps:
- uses: JuliaRegistries/TagBot@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
ssh: ${{ secrets.DOCUMENTER_KEY }}
69 changes: 69 additions & 0 deletions .github/workflows/UnitTest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
name: CI
on:
push:
branches:
- master
tags: '*'
pull_request:
concurrency:
# Skip intermediate builds: always.
# Cancel intermediate builds: only if it is a pull request build.
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
jobs:
test:
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
version:
- '1.6'
- '1.3'
- '1'
- 'nightly'
os:
- ubuntu-latest
arch:
- x64
include:
- os: windows-latest
version: '1'
arch: x64
- os: macOS-latest
version: '1'
arch: x64
- os: ubuntu-latest
version: '1'
arch: x86

steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: julia-actions/cache@v1
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
- uses: julia-actions/julia-processcoverage@v1
- uses: codecov/codecov-action@v2
with:
files: lcov.info
multithreads:
name: Julia (threads) 1 - ubuntu-latest - x64 - ${{ github.event_name }}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
with:
version: '1'
arch: 'x64'
- uses: julia-actions/cache@v1
- uses: julia-actions/julia-buildpkg@v1
- name: run test
run: julia --project --code-coverage -t4 -e 'using Pkg; Pkg.test()'
- uses: julia-actions/julia-processcoverage@v1
- uses: codecov/codecov-action@v2
with:
files: lcov.info
28 changes: 28 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: docs
on:
- push
- pull_request
jobs:
docs:
name: Documentation
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
with:
version: '1'
- run: |
julia --project=docs -e '
using Pkg
Pkg.develop(PackageSpec(path=pwd()))
Pkg.instantiate()'
- run: |
julia --project=docs -e '
using Documenter: DocMeta, doctest
using GridDetector
DocMeta.setdocmeta!(GridDetector, :DocTestSetup, :(using GridDetector); recursive=true)
doctest(GridDetector)'
- run: julia --project=docs docs/make.jl
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
7 changes: 7 additions & 0 deletions Project.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
name = "GridDetector"
uuid = "75c2d37c-541b-4fe4-8435-1b4a52ab0cde"
authors = "Ashwani Rathee"
version = "0.0.1"

[deps]
PrecompileTools = "aea7be01-6a6a-4083-8856-8a6e6704d82a"
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
# CBDetect.jl
Detect checkerboards in Julia
# GridDetector.jl
Detect grids in Julia
3 changes: 3 additions & 0 deletions docs/Project.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[deps]
Documenter = "e30172f5-a6a5-5a46-863b-614d45cd2de4"
GridDetector = "75c2d37c-541b-4fe4-8435-1b4a52ab0cde"
14 changes: 14 additions & 0 deletions docs/make.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
push!(LOAD_PATH,"../src/")
using GridDetector
using Documenter

DocMeta.setdocmeta!(GridDetector, :DocTestSetup, :(using GridDetector); recursive=true)

makedocs(;
modules=[GridDetector],
sitename="GridDetector.jl",
)

deploydocs(;
repo="github.com/ashwani-rathee/GridDetector.jl",
)
12 changes: 12 additions & 0 deletions docs/src/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
```@meta
CurrentModule = GridDetector
```

# GridDetector.jl

GridDetector.jl provides grid detection algorithms in Julia.


```@autodocs
Modules = [GridDetector]
```
11 changes: 11 additions & 0 deletions src/GridDetector.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
module GridDetector

function hello_world()
print("Hello")
end

include("precompile.jl")

export hello_world

end # module ImageCorners
7 changes: 7 additions & 0 deletions src/precompile.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
using PrecompileTools

@setup_workload begin
@compile_workload begin
hello_world()
end
end
2 changes: 2 additions & 0 deletions test/Project.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[deps]

2 changes: 2 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
using Test
using GridDetector

0 comments on commit 95ab54e

Please sign in to comment.