.README.md 1.7 KB
Newer Older
1 2 3 4 5 6 7
#### integration testing

This repository contains integration tests that validate the argo stack.

It leverages the argopkgs repo, but overrides some sources in it with
their master branch counterparts. see file `default.nix` for details.

Valentin Reis's avatar
Valentin Reis committed
8 9 10 11
The intended usage is to override (some of) the source(s) with WIP
version(s), as part of development or continuous integration. This
gitlab CI snippets shows how to do this on a nix-enabled runner. Mind that
this setup tracks argotest master.
12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36

```{.yml}
integration.test:
  stage: test
  script:
    - BUILD=$PWD
    - git clone https://xgitlab.cels.anl.gov/argo/argotest.git
    - cd argotest
    - nix-shell -A test --run "./argotk.hs helloworld" --arg nrm-src ../.
  artifacts:
    paths:
      - argotest/cmd_err.log
      - argotest/cmd_out.log
      - argotest/daemon_out.log
      - argotest/daemon_out.log
      - argotest/nrm.log
      - argotest/time.log
    expire_in: 1 week
  except:
    - /^wip\/.*/
    - /^WIP\/.*/
  tags:
    - integration
```

37 38
Standalone usage: example with the nrm source in `../`, provision the dependencies using:

39 40
```{.bash}
nix-shell -A test --arg nrm-src ../nrm
41 42 43 44 45 46
```

Then use the tool:

```{.bash}
./argotk.hs --help
47 48 49 50 51
```
Output:
```{.txt pipe="sh"}
root/argotk.hs --help
```
52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78

```{.bash}
./argotk.hs helloworld --help
```
```{.txt pipe="sh"}
root/argotk.hs helloworld --help
```

```{.bash}
./argotk.hs application --help
```
```{.txt pipe="sh"}
root/argotk.hs application --help
```

```{.bash}
./argotk.hs daemon --help
```
```{.txt pipe="sh"}
root/argotk.hs daemon --help
```

##### Hacking

- edit `.README.md` in place of README.md.

- the ./shake.hs build file takes care of a few things for the development workflow (readme and completion generation).