1 2 3 4 5 6 7 8 9 10 11 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 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61
|
# This file is part of grecs -*- Autotest -*-
# Copyright (C) 2011-2022 Sergey Poznyakoff
#
# Grecs 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 3, or (at your option)
# any later version.
#
# Grecs 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 Grecs. If not, see <http://www.gnu.org/licenses/>.
AT_SETUP(Locations: git)
AT_KEYWORDS([locus git locus-git])
AT_DATA([test.cf],[[[core]]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
[[remote "origin"]]
url = ssh://git.gnu.org.ua/gitroot/grecs.git
fetch = +refs/heads/*:refs/remotes/origin/*
])
AT_CHECK([gcffmt -type=GIT -locus test.cf],
[0],
[test.cf:2.9-35: .core.repositoryformatversion: "0"
test.cf:3.9-23: .core.filemode: "true"
test.cf:4.9-20: .core.bare: "false"
test.cf:5.9-31: .core.logallrefupdates: "true"
test.cf:7.9-52: .remote.origin.url: "ssh://git.gnu.org.ua/gitroot/grecs.git"
test.cf:8.9-51: .remote.origin.fetch: "+refs/heads/*:refs/remotes/origin/*"
])
AT_CHECK([gcffmt -type=GIT -novalue -locus test.cf],
[0],
[test.cf:2.9-31: .core.repositoryformatversion
test.cf:3.9-16: .core.filemode
test.cf:4.9-12: .core.bare
test.cf:5.9-24: .core.logallrefupdates
test.cf:7.9-11: .remote.origin.url
test.cf:8.9-13: .remote.origin.fetch
])
AT_CHECK([gcffmt -type=GIT -nopath -locus test.cf],
[0],
[test.cf:2.35: "0"
test.cf:3.20-23: "true"
test.cf:4.16-20: "false"
test.cf:5.28-31: "true"
test.cf:7.15-52: "ssh://git.gnu.org.ua/gitroot/grecs.git"
test.cf:8.17-51: "+refs/heads/*:refs/remotes/origin/*"
])
AT_CLEANUP
|