Compare commits

...

No commits in common. "c8" and "c9s" have entirely different histories.
c8 ... c9s

17 changed files with 240 additions and 4 deletions

1
.fmf/version Normal file
View File

@ -0,0 +1 @@
1

7
.gitignore vendored
View File

@ -1,2 +1,5 @@
SOURCES/d3-flame-graph-4.0.7.tar.gz
SOURCES/js-d3-flame-graph-vendor-4.0.7-1.tar.xz
/d3-flame-graph-*.tar.gz
/js-d3-flame-graph-vendor-*.tar.xz
/js-d3-flame-graph-vendor-*.tar.xz.manifest
/d3-flame-graph*/
*.rpm

View File

@ -1,2 +1,2 @@
b80fbdf125fcadec5ec1b3d8acc216f6cbd4c2d5 SOURCES/d3-flame-graph-4.0.7.tar.gz
7dafbc87ec919cdb14e5b01fbdb115a75312f7fb SOURCES/js-d3-flame-graph-vendor-4.0.7-1.tar.xz
b80fbdf125fcadec5ec1b3d8acc216f6cbd4c2d5 d3-flame-graph-4.0.7.tar.gz
7dafbc87ec919cdb14e5b01fbdb115a75312f7fb js-d3-flame-graph-vendor-4.0.7-1.tar.xz

2
README Normal file
View File

@ -0,0 +1,2 @@
The test's Makefiles are not used in Fedora CI infrastructure. But are kept here
for backward compatibility with traditional beakerlib test harness in RHEL.

26
README.md Normal file
View File

@ -0,0 +1,26 @@
# js-d3-flame-graph
The js-d3-flame-graph package
## Upgrade instructions
* update `Version`, `Release`, `%changelog` and tarball NVRs in the specfile
* create bundles and manifest: `make clean all`
* update specfile with contents of the `.manifest` file
* run local build: `rpkg local`
* run rpm linter: `rpkg lint -r js-d3-flame-graph.rpmlintrc`
* run a scratch build: `fedpkg scratch-build --srpm`
* upload new source tarballs: `fedpkg new-sources *.tar.gz *.tar.xz`
* commit new `sources` file
## Backporting
* create the patch
* declare and apply (`%prep`) the patch in the specfile
* if the patch affects Node.js dependencies
* create new tarballs
* update the specfile with new tarball path and contents of the `.manifest` file
Note: the Makefile automatically applies patches before creating the tarballs
## Patches
* `*.patch`: regular patches applied to the source, applied in the Makefile before vendoring and in the specfile (e.g. updating dependencies)
* `*.vendor.patch`: patches applied to the vendor tarball (e.g. patching vendored sources before generating a webpack)
* `*.cond.patch`: conditionally applied patches in the specfile

19
gating.yaml Normal file
View File

@ -0,0 +1,19 @@
--- !Policy
product_versions:
- fedora-*
decision_context: bodhi_update_push_stable
subject_type: koji_build
rules:
- !PassingTestCaseRule {test_case_name: fedora-ci.koji-build.tier0.functional}
--- !Policy
product_versions:
- rhel-8
decision_context: osci_compose_gate
rules:
- !PassingTestCaseRule {test_case_name: baseos-ci.brew-build.tier1.functional}
--- !Policy
product_versions:
- rhel-9
decision_context: osci_compose_gate
rules:
- !PassingTestCaseRule {test_case_name: baseos-ci.brew-build.tier1.functional}

View File

@ -0,0 +1,2 @@
addFilter("W: strange-permission list_bundled_nodejs_packages.py 755")
addFilter("W: patch-not-applied .+.vendor.patch")

View File

@ -108,5 +108,26 @@ cp -a dist/* %{buildroot}/%{_jsdir}/%{pkgname}
* Fri Oct 01 2021 Andreas Gerstmayr <agerstmayr@redhat.com> - 4.0.7-1
- update to 4.0.7 tagged upstream community sources, see CHANGELOG
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 3.0.2-7
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
Related: rhbz#1991688
* Wed Jun 30 2021 Andreas Gerstmayr <agerstmayr@redhat.com> - 3.0.2-6
- change webpack hash function to sha256
- remove unused cryptographic implementations
* Tue Jun 22 2021 Mohan Boddu <mboddu@redhat.com> - 3.0.2-5
- Rebuilt for RHEL 9 BETA for openssl 3.0
Related: rhbz#1971065
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 3.0.2-4
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 3.0.2-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.0.2-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
* Fri Mar 20 2020 Andreas Gerstmayr <agerstmayr@redhat.com> 3.0.2-1
- initial version

6
plans/ci.fmf Normal file
View File

@ -0,0 +1,6 @@
summary: CI Gating Plan
discover:
how: fmf
directory: tests
execute:
how: beakerlib

2
sources Normal file
View File

@ -0,0 +1,2 @@
SHA512 (d3-flame-graph-4.0.7.tar.gz) = 1905fbeac9cef2808330af86495ef2a4ec97a332ed24bb869ed7fe71e0cdf44da179c66464dff125ced2be0768a7fe6f73971dbc4d01f7e39725dd3527ebd05a
SHA512 (js-d3-flame-graph-vendor-4.0.7-1.tar.xz) = 1648ff25b800932bb5cdfdfdd8505eb18d0e097c7ea7919ad2a98fdd72ec0ee65ff1bdd67c331b14a8eeb0f3ea533c4b0c0779205ba386c1ed4d8c054328fc53

View File

@ -0,0 +1,65 @@
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Makefile of /tools/js-d3-flame-graph/Sanity/upstream-testsuite
# Description: Upstream sanity testsuite
# Author: Jan Kuřík <jkurik@redhat.com>
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Copyright (c) 2020 Red Hat, Inc.
#
# This program is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation, either version 2 of
# the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be
# useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
# PURPOSE. See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see http://www.gnu.org/licenses/.
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
export TEST=/tools/js-d3-flame-graph/Sanity/upstream-testsuite
export TESTVERSION=1.0
BUILT_FILES=
FILES=$(METADATA) runtest.sh Makefile PURPOSE
.PHONY: all install download clean
run: $(FILES) build
./runtest.sh
build: $(BUILT_FILES)
test -x runtest.sh || chmod a+x runtest.sh
clean:
rm -f *~ $(BUILT_FILES)
include /usr/share/rhts/lib/rhts-make.include
$(METADATA): Makefile
@echo "Owner: Jan Kuřík <jkurik@redhat.com>" > $(METADATA)
@echo "Name: $(TEST)" >> $(METADATA)
@echo "TestVersion: $(TESTVERSION)" >> $(METADATA)
@echo "Path: $(TEST_DIR)" >> $(METADATA)
@echo "Description: Upstream sanity testsuite" >> $(METADATA)
@echo "Type: Sanity" >> $(METADATA)
@echo "TestTime: 15m" >> $(METADATA)
@echo "RunFor: js-d3-flame-graph" >> $(METADATA)
@echo "Requires: js-d3-flame-graph nodejs" >> $(METADATA)
@echo "Requires: make rpm-build" >> $(METADATA)
@echo "Priority: Normal" >> $(METADATA)
@echo "License: GPLv2+" >> $(METADATA)
@echo "Confidential: no" >> $(METADATA)
@echo "Destructive: no" >> $(METADATA)
@echo "Bug: 1788348" >> $(METADATA)
@echo "Releases: -RHEL4 -RHEL6 -RHEL7 -RHELClient5 -RHELServer5" >> $(METADATA)
rhts-lint $(METADATA)

View File

@ -0,0 +1,3 @@
PURPOSE of /tools/js-d3-flame-graph/Sanity/upstream-testsuite
Description: Upstream sanity testsuite
Author: Jan Kuřík <jkurik@redhat.com>

View File

@ -0,0 +1,16 @@
summary: Upstream sanity testsuite
description: ''
contact:
- Jan Kuřík <jkurik@redhat.com>
component:
- js-d3-flame-graph
test: ./runtest.sh
framework: beakerlib
recommend:
- js-d3-flame-graph
- nodejs
- make
- rpm-build
duration: 15m
extra-summary: /tools/js-d3-flame-graph/Sanity/upstream-testsuite
extra-task: /tools/js-d3-flame-graph/Sanity/upstream-testsuite

View File

@ -0,0 +1,70 @@
#!/bin/bash
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# runtest.sh of /tools/js-d3-flame-graph/Sanity/upstream-testsuite
# Description: Upstream sanity testsuite
# Author: Jan Kuřík <jkurik@redhat.com>
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Copyright (c) 2020 Red Hat, Inc.
#
# This program is free software: you can redistribute it and/or
# modify it under the terms of the GNU General Public License as
# published by the Free Software Foundation, either version 2 of
# the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be
# useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
# PURPOSE. See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see http://www.gnu.org/licenses/.
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Include Beaker environment
. /usr/share/beakerlib/beakerlib.sh || exit 1
PACKAGE="js-d3-flame-graph"
rlJournalStart
rlPhaseStartSetup
rlAssertRpm "${PACKAGE}" ||\
rlDie "Can not recover from the previous error"
rlFileBackup --missing-ok "/root/.npm" "/root/.bashrc"
rlRun "rm -rf /root/.npm"
rlRun "TmpDir=\$(mktemp -d)" 0 "Creating tmp directory"
rlRun "pushd ${TmpDir}"
rlPhaseEnd
rlPhaseStartTest "Prepare ${PACKAGE} for testing"
rlFetchSrcForInstalled "${PACKAGE}" \
|| rlDie "Can not download SRPM of ${PACKAGE} - giving up"
rlRun "rpm -D \"_topdir ${TmpDir}\" -U \
$(rpm -q --qf '%{name}-%{version}-%{release}.src.rpm' ${PACKAGE}.noarch)"
rlRun "rpmbuild --nodeps -D \"_topdir ${TmpDir}\" \
-bp ${TmpDir}/SPECS/${PACKAGE}.spec"
rlPhaseEnd
rlPhaseStartTest "Run the upstream testsuite"
BDIR=$(rpm -q --qf '%{name}-%{version}' ${PACKAGE}.noarch)
P=$(sed 's/^js-//' <<< "${BDIR}")
if rlRun "pushd ${TmpDir}/BUILD/${P}/test"; then
rlRun "npm run test"
rlRun "popd"
else
rlFail "Can not find the working directory of the upstream testsuite"
fi
rlPhaseEnd
rlPhaseStartCleanup
rlRun "popd"
rlRun "rm -rf ${TmpDir}" 0 "Removing tmp directory"
rlRun "rm -rf /root/.npm"
rlFileRestore
rlPhaseEnd
rlJournalPrintText
rlJournalEnd