Commit ee29f207 authored by Chandan Singh's avatar Chandan Singh
Browse files

Merge branch 'chandan/no-sdist' into 'master'

.gitlab-ci.yml: Remove prepare stage

See merge request !1037
parents 45692335 f42dcb54
Loading
Loading
Loading
Loading
Loading
+5 −44
Original line number Original line Diff line number Diff line
@@ -6,7 +6,6 @@ cache:
    - cache/
    - cache/


stages:
stages:
  - prepare
  - test
  - test
  - post
  - post


@@ -15,41 +14,6 @@ variables:
  INTEGRATION_CACHE: "${CI_PROJECT_DIR}/cache/integration-cache"
  INTEGRATION_CACHE: "${CI_PROJECT_DIR}/cache/integration-cache"
  TEST_COMMAND: "tox -- --color=yes --integration"
  TEST_COMMAND: "tox -- --color=yes --integration"


#####################################################
#                  Prepare stage                    #
#####################################################

# Create a source distribution
#
source_dist:
  stage: prepare
  script:

  # Generate the source distribution tarball
  #
  - python3 setup.py sdist
  - tar -ztf dist/*
  - tarball=$(cd dist && echo $(ls *))

  # Verify that the source distribution tarball can be installed correctly
  #
  - pip3 install dist/*.tar.gz
  - bst --version

  # unpack tarball as `dist/buildstream` directory
  - |
    cat > dist/unpack.sh << EOF
    #!/bin/sh
    tar -zxf ${tarball}
    mv ${tarball%.tar.gz} buildstream
    EOF

  # Make our helpers executable
  - chmod +x dist/unpack.sh
  artifacts:
    paths:
    - dist/



#####################################################
#####################################################
#                    Test stage                     #
#                    Test stage                     #
@@ -72,8 +36,7 @@ source_dist:
  - useradd -Um buildstream
  - useradd -Um buildstream
  - chown -R buildstream:buildstream .
  - chown -R buildstream:buildstream .


  # Run the tests from the source distribution, We run as a simple
  # Run the tests as a simple user to test for permission issues
  # user to test for permission issues
  - su buildstream -c "${TEST_COMMAND}"
  - su buildstream -c "${TEST_COMMAND}"


  after_script:
  after_script:
@@ -192,7 +155,8 @@ docs:
    scheduler:
    scheduler:
      fetchers: 2
      fetchers: 2
    EOF
    EOF
  - (cd dist && ./unpack.sh && cd buildstream && pip3 install .)
  - pip3 install -r requirements/requirements.txt -r requirements/plugin-requirements.txt
  - pip3 install --no-index .
  - pip3 install --user -e ${BST_EXT_URL}@${BST_EXT_REF}#egg=bst_ext
  - pip3 install --user -e ${BST_EXT_URL}@${BST_EXT_REF}#egg=bst_ext
  - git clone https://gitlab.com/freedesktop-sdk/freedesktop-sdk.git
  - git clone https://gitlab.com/freedesktop-sdk/freedesktop-sdk.git
  - git -C freedesktop-sdk checkout ${FD_SDK_REF}
  - git -C freedesktop-sdk checkout ${FD_SDK_REF}
@@ -275,13 +239,12 @@ coverage:
  stage: post
  stage: post
  coverage: '/TOTAL +\d+ +\d+ +(\d+\.\d+)%/'
  coverage: '/TOTAL +\d+ +\d+ +(\d+\.\d+)%/'
  script:
  script:
    - cd dist && ./unpack.sh && cd buildstream
    - pip3 install -r requirements/requirements.txt -r requirements/dev-requirements.txt
    - pip3 install -r requirements/requirements.txt -r requirements/dev-requirements.txt
    - pip3 install --no-index .
    - pip3 install --no-index .
    - mkdir report
    - mkdir report
    - cd report
    - cd report
    - cp ../../../coverage-unix/coverage.* .
    - cp ../coverage-unix/coverage.* .
    - cp ../../../coverage-linux/coverage.* .
    - cp ../coverage-linux/coverage.* .
    - ls coverage.*
    - ls coverage.*
    - coverage combine --rcfile=../.coveragerc -a coverage.*
    - coverage combine --rcfile=../.coveragerc -a coverage.*
    - coverage report --rcfile=../.coveragerc -m
    - coverage report --rcfile=../.coveragerc -m
@@ -290,7 +253,6 @@ coverage:
  - tests-fedora-27
  - tests-fedora-27
  - tests-fedora-28
  - tests-fedora-28
  - tests-unix
  - tests-unix
  - source_dist
  except:
  except:
  - schedules
  - schedules


@@ -299,7 +261,6 @@ coverage:
pages:
pages:
  stage: post
  stage: post
  dependencies:
  dependencies:
  - source_dist
  - docs
  - docs
  variables:
  variables:
    ACME_DIR: public/.well-known/acme-challenge
    ACME_DIR: public/.well-known/acme-challenge