Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions .github/workflows/cfengine_cli.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Lint policy and check formatting with CFEngine CLI
on:
workflow_call:
permissions:
contents: read
jobs:
lint:
runs-on: ubuntu-24.04
steps:
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.14"
- name: Checkout masterfiles
uses: actions/checkout@v7
- name: Install CFEngine CLI
run: pipx install cfengine
- name: Run cfengine lint
run: |
cfengine lint --strict no ./
- name: Run cfengine format --check
run: |
cfengine format --check
3 changes: 3 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@ on:
branches: [ master, 3.27.x, 3.24.x ]

jobs:
cfengine_cli:
uses: ./.github/workflows/cfengine_cli.yml
unit_tests:
needs: cfengine_cli
uses: ./.github/workflows/unit_tests.yml
shellcheck_tests:
uses: ./.github/workflows/shellcheck.yml
Expand Down
264 changes: 0 additions & 264 deletions tests/acceptance/01_vars/02_functions/staging/datatype.cf

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ bundle agent check
"$(G.perl) -e 'my $x = qw/x/ x $(testlengths); print $x;'", "useshell"
);

"length_$(testlengths)" int => strlen("$(result_$(testlengths))");
"length_$(testlengths)" int => string_length("$(result_$(testlengths))");

classes:
"ok_$(testlengths)"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ body delete init_delete
bundle agent test
{
vars:
"teststr" str => readfile("$(G.testfile)", 1000);
"teststr" string => readfile("$(G.testfile)", 1000);

"cnt"
int => parsestringarrayidx(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ body delete init_delete
bundle agent test
{
vars:
"teststr" str => readfile("$(G.testfile)", "", ":"1000);
"teststr" string => readfile("$(G.testfile)");
"cnt" int => parsestringarrayidx("ary", "$(teststr)", "", ":", 10, 1000);
"num" int => "9";
}
Expand Down
Loading
Loading