~charlesk/indicator-session/lp-1085100

« back to all changes in this revision

Viewing changes to Makefile.am

  • Committer: Charles Kerr
  • Date: 2012-05-03 00:25:16 UTC
  • mto: This revision was merged to the branch mainline in revision 346.
  • Revision ID: charles.kerr@canonical.com-20120503002516-mcdzvq5m2g0toqnh
extract the strings test into their own Makefile so that we can share it among other indicators

Show diffs side-by-side

added added

removed removed

Lines of Context:
40
40
                        echo Failed to generate AUTHORS: not a branch >&2; \
41
41
        fi
42
42
 
43
 
TESTS = \
44
 
        test-ellipsis \
45
 
        test-space-ellipsis \
46
 
        test-ascii-quotes
47
 
 
48
 
#####
49
 
# Tests for there being proper ellipsis instead of three periods in a row
50
 
#####
51
 
test-ellipsis: po
52
 
        @echo "#!/bin/bash" > $@
53
 
        @echo "(cd po && make $(GETTEXT_PACKAGE).pot)" >> $@
54
 
        @echo "grep -c -e \"^msgid.*\.\.\.\\\"\" po/$(GETTEXT_PACKAGE).pot > /dev/null && echo \"Ellipsis found in user visible strings\" >&2 && exit 1" >> $@
55
 
        @echo "exit 0" >> $@
56
 
        @chmod +x $@
57
 
 
58
 
#####
59
 
# Tests for there being a space before an ellipsis
60
 
#####
61
 
test-space-ellipsis: po
62
 
        @echo "#!/bin/bash" > $@
63
 
        @echo "(cd po && make $(GETTEXT_PACKAGE).pot)" >> $@
64
 
        @echo "grep -c -e \"^msgid.* …\\\"\" po/$(GETTEXT_PACKAGE).pot > /dev/null && echo \"Space before ellipsis found in user visible strings\" >&2 && exit 1" >> $@
65
 
        @echo "exit 0" >> $@
66
 
        @chmod +x $@
67
 
 
68
 
#####
69
 
# Tests for ASCII quote types
70
 
#####
71
 
test-ascii-quotes: po
72
 
        @echo "#!/bin/bash" > $@
73
 
        @echo "(cd po && make $(GETTEXT_PACKAGE).pot)" >> $@
74
 
        @echo "grep -c -e \"^msgid \\\".*'.*\\\"\" po/$(GETTEXT_PACKAGE).pot > /dev/null && echo \"ASCII apostrophy found in user visible strings\" >&2 && exit 1" >> $@
75
 
        @echo "grep -c -e \"^msgid \\\".*\\\".*\\\"\" po/$(GETTEXT_PACKAGE).pot > /dev/null && echo \"ASCII quote found in user visible strings\" >&2 && exit 1" >> $@
76
 
        @echo "grep -c -e \"^msgid \\\".*\\\`.*\\\"\" po/$(GETTEXT_PACKAGE).pot > /dev/null && echo \"ASCII backtick found in user visible strings\" >&2 && exit 1" >> $@
77
 
        @echo "exit 0" >> $@
78
 
        @chmod +x $@
79
 
 
80
 
CLEANFILES = $(TESTS)
81
 
 
82
43
include $(top_srcdir)/Makefile.am.coverage