File: cpp_with_spaces.py

package info (click to toggle)
exhale 0.3.7-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,616 kB
  • sloc: python: 9,057; cpp: 1,260; javascript: 915; f90: 29; ansic: 18; makefile: 16
file content (42 lines) | stat: -rw-r--r-- 1,556 bytes parent folder | download
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
# -*- coding: utf8 -*-
########################################################################################
# This file is part of exhale.  Copyright (c) 2017-2024, Stephen McDowell.             #
# Full BSD 3-Clause license available here:                                            #
#                                                                                      #
#                https://github.com/svenevs/exhale/blob/master/LICENSE                 #
########################################################################################
"""
Tests for the ``cpp_with_spaces`` project.
"""

from __future__ import unicode_literals

from testing.base import ExhaleTestCase
from testing.decorators import no_cleanup
from testing.hierarchies import compare_file_hierarchy, file_hierarchy


class CPPWithSpaces(ExhaleTestCase):
    """
    Primary test class for project ``cpp with spaces``.
    """

    test_project = "cpp with spaces"
    """.. testproject:: cpp with spaces"""

    def test_hierarchies(self):
        """
        Verify the class and file hierarchies.

        .. todo::

            Class hierarchy not tested here, need to revisit that part of the testing
            framework **as well as** stop emitting a "Class Hierarchy" on the root api
            page when it is empty.
        """
        compare_file_hierarchy(self, file_hierarchy(self.file_hierarchy_dict()))

    @no_cleanup
    def test_build(self):
        """Verify that the sphinx build (with spaces in filenames) succeeds."""
        self.app.build()