Skip to content

Commit

Permalink
start renaming bdd appendix properly
Browse files Browse the repository at this point in the history
  • Loading branch information
hjwp committed Feb 12, 2017
1 parent 4118615 commit 25a48a6
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 13 deletions.
7 changes: 3 additions & 4 deletions appendix_V_bdd_tools.asciidoc → appendix_bdd.asciidoc
Expand Up @@ -67,7 +67,7 @@ $ *tree features*
features
├── my_lists.feature
└── steps
   └── my_lists.py
└── my_lists.py
----


Expand Down Expand Up @@ -190,7 +190,7 @@ Generating Placeholder Steps
When we run `behave`, it helpfully tells us about all the steps we need to
implement:
[role="sourcecode small-code"]
[role="small-code"]
[subs="specialcharacters,quotes"]
----
$ *python manage.py behave*
Expand Down Expand Up @@ -254,7 +254,6 @@ the server-side version, for example, although it would be easy to re-add
later).

[role="sourcecode small-code"]
[role="sourcecode"]
.features/steps/my_lists.py
[source,python]
----
Expand Down Expand Up @@ -417,7 +416,7 @@ def step_impl(context, first_item_text):

Now we can run it and see our first expected failure:

[role="sourcecode small-code"]
[role="small-code"]
[subs="specialcharacters,macros"]
----
$ pass:quotes[*./manage.py behave*]
Expand Down
2 changes: 1 addition & 1 deletion atlas.json
Expand Up @@ -40,7 +40,7 @@
"appendix_Django_Class-Based_Views.asciidoc",
"appendix_III_provisioning_with_ansible.asciidoc",
"appendix_IV_testing_migrations.asciidoc",
"appendix_V_bdd_tools.asciidoc",
"appendix_bdd.asciidoc",
"appendix_VI_rest_api.asciidoc",
"appendix_VII_DjangoRestFramework.asciidoc",
"appendix_IX_cheat_sheet.asciidoc",
Expand Down
2 changes: 1 addition & 1 deletion book.asciidoc
Expand Up @@ -53,7 +53,7 @@ include::appendix_I_PythonAnywhere.asciidoc[]
include::appendix_Django_Class-Based_Views.asciidoc[]
include::appendix_III_provisioning_with_ansible.asciidoc[]
include::appendix_IV_testing_migrations.asciidoc[]
include::appendix_V_bdd_tools.asciidoc[]
include::appendix_bdd.asciidoc[]
include::appendix_VI_rest_api.asciidoc[]
include::appendix_VII_DjangoRestFramework.asciidoc[]
include::appendix_IX_cheat_sheet.asciidoc[]
Expand Down
2 changes: 1 addition & 1 deletion copy_html_to_site_and_print_toc.py
Expand Up @@ -44,7 +44,7 @@
"appendix_Django_Class-Based_Views.html",
"appendix_III_provisioning_with_ansible.html",
"appendix_IV_testing_migrations.html",
"appendix_V_bdd_tools.html",
"appendix_bdd.html",
"appendix_VI_rest_api.html",
"appendix_VII_DjangoRestFramework.html",
"appendix_IX_cheat_sheet.html",
Expand Down
2 changes: 1 addition & 1 deletion rename-chapter.sh
Expand Up @@ -12,7 +12,7 @@ git mv $OLD_CHAPTER.asciidoc $NEW_NAME.asciidoc
git mv tests/test_$OLD_CHAPTER.py tests/test_$NEW_NAME.py

mkdir source/$NEW_NAME
# git mv source/$OLD_CHAPTER/superlists source/$NEW_NAME/superlists
git mv source/$OLD_CHAPTER/superlists source/$NEW_NAME/superlists
cd source/$NEW_NAME/superlists && git checkout -b $NEW_NAME && cd ../../..

sed -i s/$OLD_CHAPTER/$NEW_NAME/g .travis.yml atlas.json book.asciidoc copy_html_to_site_and_print_toc.py tests/*.py
Expand Down
Expand Up @@ -5,18 +5,18 @@


class AppendixIITest(ChapterTest):
chapter_name = 'appendix_Django_Class-Based_Views'
previous_chapter = 'chapter_advanced_forms'
chapter_name = 'appendix_bdd'
previous_chapter = 'chapter_outside_in'

def test_listings_and_commands_and_output(self):
self.parse_listings()
self.start_with_checkout()
#self.prep_virtualenv()

# sanity checks
self.assertEqual(self.listings[0].type, 'code listing currentcontents')
self.assertEqual(self.listings[1].type, 'code listing with git ref')
self.assertEqual(self.listings[2].type, 'code listing with git ref')
self.assertEqual(self.listings[0].type, 'other command')
self.assertEqual(self.listings[4].type, 'tree')
self.assertEqual(self.listings[6].type, 'diff')

# skips
#self.skip_with_check(22, 'switch back to master') # comment
Expand Down

0 comments on commit 25a48a6

Please sign in to comment.