Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion arcade/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,6 @@ def configure_logging(level: Optional[int] = None):
'Camera',
'SimpleCamera',
'Color',
'DEFAULT_FONT_NAMES',
'EasingData',
'EmitBurst',
'EmitController',
Expand Down Expand Up @@ -521,6 +520,7 @@ def configure_logging(level: Optional[int] = None):
'isometric_grid_to_screen',
'lerp',
'lerp_vec',
'lerp_angle',
'load_animated_gif',
'load_font',
'load_sound',
Expand Down
9 changes: 4 additions & 5 deletions arcade/gl/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -214,21 +214,20 @@ def __init__(
normalized: Optional[Iterable[str]] = None,
instanced: bool = False,
):

#: The :py:class:`~arcade.gl.Buffer` this description object describes
self.buffer = buffer # type: Buffer
#: List of string attributes
self.attributes = attributes
#: List of normalized attributes
self.normalized = set() if normalized is None else set(normalized)
#: Instanced flag (bool)
self.instanced = instanced # type: bool
self.instanced: bool = instanced
#: Formats of each attribute
self.formats = [] # type: List[AttribFormat]
self.formats: List[AttribFormat] = []
#: The byte stride of the buffer
self.stride = -1 # type: int
self.stride: int = -1
#: Number of vertices in the buffer
self.num_vertices = -1 # type: int
self.num_vertices: int = -1

if not isinstance(buffer, Buffer):
raise ValueError("buffer parameter must be an arcade.gl.Buffer")
Expand Down
22 changes: 22 additions & 0 deletions tests/unit2/test_arcade.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,27 @@
from types import ModuleType
from copy import copy
import logging
import arcade
from arcade import *


def test_import():
"""Compare arcade.__all__ to the actual module contents"""
import arcade
global_names = set(k for k in globals() if not k.startswith('_'))
arcade_names = set(k for k in arcade.__dict__ if not k.startswith('_'))

# Get the common members
common = global_names.intersection(arcade_names)
remaining = arcade_names - common
for name in copy(remaining):
attr = getattr(arcade, name)
if type(attr) is ModuleType:
remaining.remove(name)
elif not attr.__module__.startswith('arcade.'):
remaining.remove(name)

assert len(remaining) == 0


def test_logging():
Expand Down