Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Full review and some refactoring (#124)
- Loading branch information
Showing
16 changed files
with
425 additions
and
233 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,6 +8,6 @@ MANIFEST | |
.pydevproject | ||
.settings/ | ||
testing/ | ||
tests/ | ||
tests1/ | ||
vk_config.json | ||
vk_config.v2.json |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
pytest | ||
pytest-mock |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
from jconfig.memory import MemoryConfig | ||
|
||
|
||
def test_config_section(): | ||
c = MemoryConfig('secret') | ||
|
||
assert 'secret' in c._settings | ||
|
||
c.test = 'hello!' | ||
|
||
assert c['test'] == 'hello!' | ||
assert c.test == 'hello!' | ||
assert c._section == {'test': 'hello!'} | ||
|
||
c['test'] = '42' | ||
|
||
assert c['test'] == '42' | ||
assert c.test == '42' | ||
assert c._section == {'test': '42'} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# -*- coding: utf-8 -*- | ||
""" | ||
@author: python273 | ||
@contact: https://vk.com/python273 | ||
@license Apache License, Version 2.0, see LICENSE file | ||
Copyright (C) 2018 | ||
""" | ||
|
||
from enum import Enum | ||
|
||
|
||
class VkUserPermissions(Enum): | ||
NOTIFY = 1 | ||
FRIEND = 2 | ||
PHOTOS = 2**2 | ||
AUDIO = 2**3 | ||
VIDEO = 2**4 | ||
STORIES = 2**6 | ||
PAGES = 2**7 | ||
ADD_LINK = 2**8 | ||
STATUS = 2**10 | ||
NOTES = 2**11 | ||
MESSAGES = 2**12 | ||
WALL = 2**13 | ||
ADS = 2**15 | ||
OFFLINE = 2**16 | ||
DOCS = 2**17 | ||
GROUPS = 2**18 | ||
NOTIFICATIONS = 2**19 | ||
STATS = 2**20 | ||
EMAIL = 2**22 | ||
MARKET = 2**27 |
Oops, something went wrong.