-
Notifications
You must be signed in to change notification settings - Fork 10
Submitting tests #26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
drewferris
wants to merge
14
commits into
sea-401d5-javascript:master
Choose a base branch
from
drewferris:submitting-tests
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Submitting tests #26
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
1757fa1
wrote intial files moving onto files in app dir
1070eda
writing files in app
d7ab239
got the first directives working
e6769f7
submitting
15badc7
got something displaying
5993b2a
got photos working and hiding
de7f1d3
got photos working and hiding
917188a
ready to submit
426a0ec
made test
d88c7ef
made tests for properties in the three directives that carried over f…
625c6e2
tested properties in album directive and made it so h3s added for oth…
62e41ac
commitig for aaron
8bb371f
somethingn
6a12b18
made some morre tests work
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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,7 @@ | ||
| **/node_modules/* | ||
| **/vendor/* | ||
| **/*.min.js | ||
| **/build/* | ||
| **/test/*_bundle* | ||
| *.md | ||
| package.json |
This file contains hidden or 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,45 @@ | ||
| { | ||
| "rules": { | ||
| "no-console": 0, | ||
| "indent": [ | ||
| 2, | ||
| 2, | ||
| { | ||
| "SwitchCase": 1 | ||
| } | ||
| ], | ||
| "quotes": [ | ||
| 2, | ||
| "single" | ||
| ], | ||
| "linebreak-style": [ | ||
| 2, | ||
| "unix" | ||
| ], | ||
| "semi": [ | ||
| 2, | ||
| "always" | ||
| ] | ||
| }, | ||
| "env": { | ||
| "es6": true, | ||
| "node": true, | ||
| "browser": true, | ||
| "mocha": true, | ||
| "jasmine": true | ||
| }, | ||
| "globals": { | ||
| "describe": false, | ||
| "it": false, | ||
| "beforeEach": false, | ||
| "afterEach": false, | ||
| "before": false, | ||
| "after": false | ||
| }, | ||
| "ecmaFeatures": { | ||
| "modules": true, | ||
| "experimentalObjectRestSpread": true, | ||
| "impliedStrict": true | ||
| }, | ||
| "extends": "eslint:recommended" | ||
| } |
This file contains hidden or 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,105 @@ | ||
| # Created by https://www.gitignore.io/api/node,osx,windows,vim | ||
|
|
||
| ### Node ### | ||
| # Logs | ||
| logs | ||
| *.log | ||
| npm-debug.log* | ||
|
|
||
| # Runtime data | ||
| pids | ||
| *.pid | ||
| *.seed | ||
|
|
||
| # Directory for instrumented libs generated by jscoverage/JSCover | ||
| lib-cov | ||
|
|
||
| # Coverage directory used by tools like istanbul | ||
| coverage | ||
|
|
||
| # nyc test coverage | ||
| .nyc_output | ||
|
|
||
| # Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files) | ||
| .grunt | ||
|
|
||
| # node-waf configuration | ||
| .lock-wscript | ||
|
|
||
| # Compiled binary addons (http://nodejs.org/api/addons.html) | ||
| build/Release | ||
|
|
||
| # Dependency directories | ||
| node_modules | ||
| jspm_packages | ||
|
|
||
| # Optional npm cache directory | ||
| .npm | ||
|
|
||
| # Optional REPL history | ||
| .node_repl_history | ||
|
|
||
|
|
||
| ### OSX ### | ||
| *.DS_Store | ||
| .AppleDouble | ||
| .LSOverride | ||
|
|
||
| # Icon must end with two \r | ||
| Icon | ||
|
|
||
|
|
||
| # Thumbnails | ||
| ._* | ||
|
|
||
| # Files that might appear in the root of a volume | ||
| .DocumentRevisions-V100 | ||
| .fseventsd | ||
| .Spotlight-V100 | ||
| .TemporaryItems | ||
| .Trashes | ||
| .VolumeIcon.icns | ||
| .com.apple.timemachine.donotpresent | ||
|
|
||
| # Directories potentially created on remote AFP share | ||
| .AppleDB | ||
| .AppleDesktop | ||
| Network Trash Folder | ||
| Temporary Items | ||
| .apdisk | ||
|
|
||
|
|
||
| ### Windows ### | ||
| # Windows image file caches | ||
| Thumbs.db | ||
| ehthumbs.db | ||
|
|
||
| /build | ||
|
|
||
| # Folder config file | ||
| Desktop.ini | ||
|
|
||
| # Recycle Bin used on file shares | ||
| $RECYCLE.BIN/ | ||
|
|
||
| # Windows Installer files | ||
| *.cab | ||
| *.msi | ||
| *.msm | ||
| *.msp | ||
|
|
||
| # Windows shortcuts | ||
| *.lnk | ||
|
|
||
|
|
||
| ### Vim ### | ||
| # swap | ||
| [._]*.s[a-w][a-z] | ||
| [._]s[a-w][a-z] | ||
| # session | ||
| Session.vim | ||
| # temporary | ||
| .netrwhist | ||
| *~ | ||
| # auto-generated tag files | ||
| tags |
This file contains hidden or 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,4 @@ | ||
| ul | ||
| { | ||
| list-style-type: none; | ||
| } |
This file contains hidden or 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,29 @@ | ||
| <!doctype html> | ||
| <html> | ||
|
|
||
| <head> | ||
| <meta charset="utf-8"> | ||
| <meta name="description" content=""> | ||
| <meta name="viewport" content="width=device-width, initial-scale=1"> | ||
| <title>Butt Sniffer App</title> | ||
| <link rel="stylesheet" href="app.css"> | ||
| </head> | ||
|
|
||
| <body data-ng-app="ButtSnifferApp"> | ||
| <main ng-cloak ng-controller="PhotoAlbumController as albums"> | ||
|
|
||
| <h1>{{albums.sugarGliders.title}}</h1> | ||
| <h3>{{albums.sugarGliders.description}}</h1> | ||
| <photo-album photos="albums.sugarGliders.album"></photo-album> | ||
| <h1>{{albums.badPussyCats.title}}</h1> | ||
| <h3>{{albums.badPussyCats.description}}</h1> | ||
| <photo-album photos="albums.badPussyCats.album"></photo-album> | ||
| <h1>{{albums.superCoolMarineIguanas.title}}</h1> | ||
| <h3>{{albums.superCoolMarineIguanas.description}}</h1> | ||
| <photo-album photos="albums.superCoolMarineIguanas.album"></photo-album> | ||
|
|
||
| </main> | ||
| <script src="bundle.js"></script> | ||
| </body> | ||
|
|
||
| </html> |
This file contains hidden or 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,6 @@ | ||
| 'use strict'; | ||
|
|
||
| const angular = require('angular'); | ||
|
|
||
| let ButtSnifferApp = angular.module('ButtSnifferApp', []); | ||
| require('./first')(ButtSnifferApp); |
This file contains hidden or 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,14 @@ | ||
| 'use strict'; | ||
|
|
||
| module.exports = function(app) { | ||
| app.controller('ButtSnifferController', ['$scope', function() { | ||
| this.url = 'http://www.wagandtrain.com/wp-content/plugins/image-shadow/cache/800d8ab9cf449d827c7d4d4a24ae0cc8.jpg'; | ||
| this.height = 400; | ||
| this.width = 400; | ||
| this.title = 'Butt Sniffer'; | ||
| this.description = 'Look at this crazy butt sniffer, how did he get there?'; | ||
| this.title = ''; | ||
| this.description = ''; | ||
| this.album = []; | ||
| }]); | ||
| }; |
This file contains hidden or 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,67 @@ | ||
| 'use strict'; | ||
|
|
||
| module.exports = function(app) { | ||
| app.controller('PhotoAlbumController', PhotoAlbumController); | ||
| }; | ||
|
|
||
| function PhotoAlbumController() { | ||
|
|
||
| this.sugarGliders = { | ||
| title: 'Sugar Gliders Album All The Way!!', | ||
| description: 'Damn these gliders sure are nasty :)', | ||
| album: [ | ||
| { | ||
| url: 'http://f.tqn.com/y/exoticpets/1/W/R/Q/1/96747320-crop.jpg', | ||
| title: 'Chillin on some wood, no glide mode', | ||
| textDisplay: false | ||
| }, | ||
| { | ||
| url: 'http://www.rkpuppiesandmore.com/smallpets/sugarglider.jpg', | ||
| title: 'Ridin that I dont know what, but supermanning that surface', | ||
| textDisplay: false | ||
| }, | ||
| { | ||
| url: 'http://rainforestreports.weebly.com/uploads/1/5/5/7/15578800/8932099_orig.jpg', | ||
| title: 'Swoopin in on yall', | ||
| textDisplay: false | ||
| } | ||
| ] | ||
| }; | ||
| this.badPussyCats = { | ||
| title: 'These pussies are super bad!!!', | ||
| description: 'Who let these pussies out?', | ||
| album: [ | ||
| { | ||
| url: 'https://s-media-cache-ak0.pinimg.com/236x/d8/10/e4/d810e49915d82f8b281d07f9b0d55cd7.jpg', | ||
| title: 'Damn this pussy is getting locked up' | ||
| }, | ||
| { | ||
| url: 'http://1.bp.blogspot.com/_DTGEcBi-w0g/TIg0BOQWHuI/AAAAAAAAAmI/UeFySd1t6Yw/s640/bad-cat3.jpg', | ||
| title: 'Back in da hood pussy' | ||
| }, | ||
| { | ||
| url: 'https://secure.static.tumblr.com/468c354df166018752850b504e7a4561/earrb7t/xoLnoany6/tumblr_static_tumblr_static_2rtorf46vu0w4kgc8gowcc4gk_640.jpg', | ||
| title: 'This pussy is far out man' | ||
| } | ||
| ] | ||
| }; | ||
|
|
||
| this.superCoolMarineIguanas = { | ||
| title: 'Bet you didnt know about these guys', | ||
| description: 'Marine Iguanas on the rise', | ||
| album: [ | ||
| { | ||
| url: 'https://www.quasarex.com/galapagos/media/img/animals/reptiles/iguanas/marine-iguanas_2.jpg', | ||
| title: 'Here he is, front and center' | ||
| }, | ||
| { | ||
| url: 'http://ww2.hdnux.com/photos/45/27/47/9796073/4/920x920.jpg', | ||
| title: 'They like to swim' | ||
| }, | ||
| { | ||
| url: 'http://yourshot.nationalgeographic.com/u/ss/fQYSUbVfts-T7pS2VP2wnKyN8wxywmXtY0-FwsgxpiuUfORQIJSJ-23I0H_e0r-hPtf9foGX8_K9EEouT8ey/', | ||
| title: 'And spit!' | ||
| } | ||
| ] | ||
| }; | ||
| } |
This file contains hidden or 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,4 @@ | ||
| module.exports = function(app) { | ||
| require('./ButtSnifferController')(app); | ||
| require('./PhotoAlbumController')(app); | ||
| }; |
This file contains hidden or 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,35 @@ | ||
| module.exports = function(app) { | ||
| app.directive('photoAlbum', function() { | ||
| return { | ||
| restrict: 'E', | ||
| templateUrl: './templates/first/albums.html', | ||
| scope: { | ||
| photos: '=', | ||
| title: '=', | ||
| description: '=', | ||
| photo: '=' | ||
| }, | ||
| controller: function($scope) { | ||
| $scope.photoText = false; | ||
| $scope.photoTextAgain = true; | ||
| $scope.test = false; | ||
| $scope.changeView = function() { | ||
| console.log($scope.mode); | ||
| }; | ||
| $scope.toggle = function(photo) { | ||
| console.log(photo); | ||
|
|
||
| $scope.currentPhoto = photo; | ||
| let photoArray = []; | ||
| photoArray.push(photo); | ||
| console.log(photoArray); | ||
|
|
||
| $scope.photoText = !$scope.photoText; | ||
| $scope.photoTextAgain = !$scope.photoTextAgain; | ||
|
|
||
|
|
||
| }; | ||
| } | ||
| }; | ||
| }); | ||
| }; |
This file contains hidden or 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,11 @@ | ||
| module.exports = function(app) { | ||
| app.directive('dummy', function() { | ||
| return { | ||
| templateUrl: './templates/first/dummy.html', | ||
| scope: { | ||
| data: '=' | ||
| }, | ||
| replace: true | ||
| }; | ||
| }); | ||
| }; |
This file contains hidden or 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,14 @@ | ||
| module.exports = function(app) { | ||
| app.directive('fullImageDirective', function() { | ||
| return { | ||
| restrict: 'E', | ||
| templateUrl: './templates/first/full_image_template.html', | ||
| replace: true, | ||
| scope: { | ||
| url: '=', | ||
| title: '=', | ||
| description: '=' | ||
| } | ||
| }; | ||
| }); | ||
| }; |
This file contains hidden or 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,7 @@ | ||
| module.exports = function(app) { | ||
| require('./full_image_directive')(app); | ||
| require('./title_directive')(app); | ||
| require('./tiny_image_directive')(app); | ||
| require('./album_directive')(app); | ||
| require('./dummy')(app); | ||
| }; |
This file contains hidden or 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,15 @@ | ||
| module.exports = function(app) { | ||
| app.directive('tinyImageDirective', function() { | ||
| return { | ||
| restrict: 'E', | ||
| templateUrl: './templates/first/tiny_image_template.html', | ||
| scope: { | ||
| title: '=', | ||
| url: '=', | ||
| height: '@100', | ||
| width: '@100', | ||
| description: '=' | ||
| } | ||
| }; | ||
| }); | ||
| }; |
This file contains hidden or 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,13 @@ | ||
| module.exports = function(app) { | ||
| app.directive('firstImageDirective', function() { | ||
| return { | ||
| restrict: 'E', | ||
| templateUrl: './templates/first/title_image_template.html', | ||
| scope: { | ||
| title: '=', | ||
| url: '=', | ||
| description: '=' | ||
| } | ||
| }; | ||
| }); | ||
| }; | ||
This file contains hidden or 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,4 @@ | ||
| module.exports = function(app) { | ||
| require('./controllers')(app); | ||
| require('./directives')(app); | ||
| }; |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For consistency you should name your directive the same as the file name. That way if someone is tracing your code looking for 'firstImageDirective' they will know where to look. Think of yourself six months from now looking back at your code and trying to remember where you put things.